QPaintDevice: Must construct a QApplication before a QPaintDevice
Hi,
My Application uses QApplication before creating any QT widget's, but still i am getting this issue .
My application is service component based application which is build-ed using QT 4.5.3 and when i request my service to load the component it loads the component(It uses QT classes 3.3.6) which requires QT_MT336.dll which i had copied.
So in general My QT Application version is 4.5.3 and the component that it loads dynamically is builded using 3.3.6.
Is this the reason for the bug?If yes then what work-around would you suggest so that i don't need to build the component (QT 3.3.6 ) again to QT 4.5.
Can't QT 4.5 use the QT 3.3.6 code (Backward Compatibility) ? .
Any help would be appreciated .
Thanks.
Re: QPaintDevice: Must construct a QApplication before a QPaintDevice
Different versions are not binary compatible, so you cannot use 3.x libraries with 4.x code.
Point releases are binary compatible, so you can use 4.x libraries with 4.x code.
You need to rebuild.
http://developer.qt.nokia.com/faq/an...ary_compatible
Re: QPaintDevice: Must construct a QApplication before a QPaintDevice
Do you think "Must construct a QApplication before a QPaintDevice " error message is possible cause of different version's of QT libraries (4.5.3 to 3.3.6 )that are loaded .?
Re: QPaintDevice: Must construct a QApplication before a QPaintDevice
Why not? The library expects a Qt 3 QApplication while you have created a Qt 4 QApplication. Possible. Make a small test case and see.
Re: QPaintDevice: Must construct a QApplication before a QPaintDevice
Quote:
Originally Posted by
vaibhav
Do you think "Must construct a QApplication before a QPaintDevice " error message is possible cause of different version's of QT libraries (4.5.3 to 3.3.6 )that are loaded .?
Please dont tell me you are going to ignore the fact the versions are not compatible and try to make things work?