Unsolved new project has lots of semantic error
-
-
@ggnohope
Hello and welcome.Please state how your situation differs from the link you reference, where the reply was:
@jsulm said in Qt CMake Semantic Issue:
@qtcat Did you build your app?
ui_mainwindow.h is a file which is generated during build. If it is not yet there (because you did not yet build), QtCreator will show this errors/warnings because it does not know what Ui::MainWindow, which comes from that generated file, is. -
@JonB I'm having a similar problem with CMake using Qt6. I can't get the program to run and i can't get it past this point, since the ui_mainwindow.h file cannot be found.
Please assist if possible. I have gone through the existing threads on this issue and none of the previous solutions or suggestions have worked.
-
@JRaith
My previous reply states what the problem is. You either have not done a build which would generate theui_....h
file from the.ui
file, or from what I can see you don't even seem to have any.ui
file so I have no idea where you got the code from or expect it to work if that is the case. -
@JRaith The easiest solution you could go with, is to create a new widgets project, and just get the code you need from this project to replicate it.
And if this is not your original code, you missed getting a ui file, most likely called
mainwindow.ui
.