Error in QTCreator 4.14.1 (Python): No documents matching "ui_form.h" could be found
Asked Answered
F

3

8

I am trying to create a GUI in QTCreator using Python but whenever I try to edit the code on a button I get the following error.

Editing code on Button

Selecting the slot I want to edit

Error when selecting onClicked

I have tried rebuilding the project multiple times and I am still getting the same error.

Fang answered 25/2, 2021 at 13:56 Comment(1)
There's an old bug here that looks similar: QTCREATORBUG-9683. Maybe that regression has reappeared in whatever version you're currently using.Twibill
P
0

I had similar issues using c++, and I just added a slot in the header file and corresponding function in cpp file.

For my application, it was about the double spin box in a second window. I just followed the naming convention that qtcreator made for another example, and it worked.

in header file:

private slots:
void on_doubleSpinBox_MaxDepth_valueChanged(double arg1);

in cpp file:

void ProjectionsWindow::on_doubleSpinBox_MaxDepth_valueChanged(double arg1) {
//do something}

I'm not sure how it should be written in python, but maybe try similar method?

Paolo answered 16/7, 2023 at 23:56 Comment(0)
R
0

You probably created a UI form without its corresponding header and source file, ie. ui_ui_form.h and ui_ui_form.cpp as shown in the error message.

By choosing Qt Designer Form Class when adding a new file to your project, you will get those files auto-created for your .ui form. Please see the screenshot:

Create UI form in QtCreator with header and source

Ropy answered 9/8 at 11:16 Comment(0)
E
-1

I had the same issue. if there is a .pro file check in there to see if the form.h is in the same format as well as in your form.cpp I had to delete and re-add them and do a rebuild all and it worked I hope it works for you as well.

Echolalia answered 12/10, 2022 at 15:6 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.