Compiler Error : use of undefined type ' '
Unsolved
General and Desktop
-
wrote on 3 Mar 2017, 03:23 last edited by
Hi Community,
I get the following compiler error
C2027: use of undefined type 'QMap <QString,QVariant>' from qvariant.hAny idea what i have failed to add ?
Regards,
Vinoth R -
Hi Community,
I get the following compiler error
C2027: use of undefined type 'QMap <QString,QVariant>' from qvariant.hAny idea what i have failed to add ?
Regards,
Vinoth R@vinothrajendran4 Did you include QMap?
#include <QMap>
You should show the code causing this error.
-
Hi,
To add to @jsulm, did you add
#include <QVariant>
? -
wrote on 18 Nov 2019, 12:53 last edited by Crawl.W
When I declare a func which ret type is
QVariantList
, report errorerror: C2027: use of undefined type 'QVariant'
.In this case, we need include#include <QVariant>
in the header file.