Cannot add plugin into QtDesigner
-
Hi everyone,
I'm facing a problem when I want to use my custom widget into QtDesigner. For the moment, I try to use the example "World time clock plugin" provide with Qt, but I'm lost.
Here is what I did :- I have executed qmake
- I have build the example in debug and release
- I have placed the generated dll into the folder C:\Qt\Tools\QtCreator\bin\plugins\designer
But when I go to tools -> Form editor -> about QtDesigner plugin, both dll are detected, but failed to load : the release dll has failed because the specified procedure could not be find, and the debug dll is using another Qt library incompatible.
I don't understand those errors, if someone can help me I would be glad :)Ps : I'm using Qt 5.7, QtCreator 4.0.2 and Windows 10
Thanks !
-
Hi
Since Qt Creator is compiled with Visual Studio I think you need to compile the
Designer plugins with same version of VS as far as I understand.Basically plugins are DLLS and it didn't want to load any plugins
i compiled with mingw compiler. (on windows)Note:
While having full blown designer plugins are cool, the promote feature
also let u use own custom widgets in faster way. -
Hi mrjj !
Thanks for your response !
I'll try to compile those DLL with msvc, i will let you know if it works.
The thing is my widget is pretty "heavy", it uses databases, animations, big images... a lot of things and it will be use in other projects in the future so I don't think that the promote feature is useful -
Hi mrjj !
Thanks for your response !
I'll try to compile those DLL with msvc, i will let you know if it works.
The thing is my widget is pretty "heavy", it uses databases, animations, big images... a lot of things and it will be use in other projects in the future so I don't think that the promote feature is useful -
so, one day has passed and I can't compile with msvc... Qt can't find the compiler but I have installed it...
@-AVM Which library ? The .pro file of the example should be complete, no ?
-
@Amott
Hi
Just to be sure.
Did u also run the maintenance tool and selected
the correct Qt for Visual Studio XXX version ?

In the picture i have 5.7 installed for the mingw compiler.
And nothing for VS. -
You don't need to blindly test every MSVC version. Open QtCreator and click "About -> Qt Creator". The version used is displayed there e.g.
Qt Creator 4.0.2 Based on Qt 5.7.0 (MSVC 2013, 32 bit). That's the only version that will work and the plugin needs to be compiled in release mode.As for obtaining MSVC - Installing Qt package for MSVC does not install MSVC itself! You need to download it from Microsoft's site.
-
You don't need to blindly test every MSVC version. Open QtCreator and click "About -> Qt Creator". The version used is displayed there e.g.
Qt Creator 4.0.2 Based on Qt 5.7.0 (MSVC 2013, 32 bit). That's the only version that will work and the plugin needs to be compiled in release mode.As for obtaining MSVC - Installing Qt package for MSVC does not install MSVC itself! You need to download it from Microsoft's site.
@Chris-Kawa Yes, I have this version. Yesterday I downloaded msvc 2013 and 2015 from Microsoft's site but it said that a version is already installed
-
I finally found a solution : I have uninstalled and reinstalled QtCreator.
So now I can compile the example in msvc2015 in 32 and 64bit, I did it in release and place the generated DLL into
C:\Qt\Tools\QtCreator\bin\plugins\designer
but I still have the same error : worldtimeclockplugin.dll : %1 is not a valid Win32 application -
I finally found a solution : I have uninstalled and reinstalled QtCreator.
So now I can compile the example in msvc2015 in 32 and 64bit, I did it in release and place the generated DLL into
C:\Qt\Tools\QtCreator\bin\plugins\designer
but I still have the same error : worldtimeclockplugin.dll : %1 is not a valid Win32 application@Amott said:
So now I can compile the example in msvc2015
You need the same version of MSVC that was used to build Qt Creator.
In Qt Creator, click "Help" -> "About Qt Creator...". If it says "MSVC 2013", then you must use MSVC 2013. MSVC 2015 is not compatible.