anh5kor
18th December 2015, 05:29
I have downloaded a project which read/write the excel file in c++. The project is working fine in Visual studio 2010,I have to create a GUI for the same project.
So I tried creating a new QT project in Visual Studio2010(Visual studio is already have Qt add-in).
I added the .cpp and .hpp file of my downloaded project and tried calling the functionality from my main class.
But when I build my project in debug mode I got the below error.
1>moc_qt_excel.obj : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>qrc_qt_excel.obj : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>qt_excel.obj : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>qtmaind.lib(qtmain_win.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>msvcrtd.lib(ti_inst.obj) : error LNK2005: "private: __thiscall type_info::type_info(class type_info const &)" (??0type_info@@AAE@ABV0@@Z) already defined in LIBCMTD.lib(typinfo.obj)
1>msvcrtd.lib(ti_inst.obj) : error LNK2005: "private: class type_info & __thiscall type_info::operator=(class type_info const &)" (??4type_info@@AAEAAV0@ABV0@@Z) already defined in LIBCMTD.lib(typinfo.obj)
1>LIBCMTD.lib(crt0init.obj) : warning LNK4098: defaultlib 'msvcrtd.lib' conflicts with use of other libs; use /NODEFAULTLIB:library
1>D:\Others\Project\qt_excel\Win32\Debug\\qt_excel.e xe : fatal error LNK1169: one or more multiply defined symbols found
I searched in net about the error I got some solution about changing the project property->C/C++ ->code Generation->Runtime Library->Multi-threaded DLL(/MD) from Multi-threaded Dubug(/MTd) then I got the below error
qtmaind.lib(qtmain_win.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
Same project when I compiled in Release mode its compiled Properly.
Please let me know the problem I want the project to run under debug mode also
So I tried creating a new QT project in Visual Studio2010(Visual studio is already have Qt add-in).
I added the .cpp and .hpp file of my downloaded project and tried calling the functionality from my main class.
But when I build my project in debug mode I got the below error.
1>moc_qt_excel.obj : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>qrc_qt_excel.obj : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>qt_excel.obj : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>qtmaind.lib(qtmain_win.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
1>msvcrtd.lib(ti_inst.obj) : error LNK2005: "private: __thiscall type_info::type_info(class type_info const &)" (??0type_info@@AAE@ABV0@@Z) already defined in LIBCMTD.lib(typinfo.obj)
1>msvcrtd.lib(ti_inst.obj) : error LNK2005: "private: class type_info & __thiscall type_info::operator=(class type_info const &)" (??4type_info@@AAEAAV0@ABV0@@Z) already defined in LIBCMTD.lib(typinfo.obj)
1>LIBCMTD.lib(crt0init.obj) : warning LNK4098: defaultlib 'msvcrtd.lib' conflicts with use of other libs; use /NODEFAULTLIB:library
1>D:\Others\Project\qt_excel\Win32\Debug\\qt_excel.e xe : fatal error LNK1169: one or more multiply defined symbols found
I searched in net about the error I got some solution about changing the project property->C/C++ ->code Generation->Runtime Library->Multi-threaded DLL(/MD) from Multi-threaded Dubug(/MTd) then I got the below error
qtmaind.lib(qtmain_win.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in BasicExcel.obj
Same project when I compiled in Release mode its compiled Properly.
Please let me know the problem I want the project to run under debug mode also