View Single Post

  #1 (permalink)  
Old 09-01-2005
rules rules is offline
Junior Member
White Belt
 
Join Date: Aug 2005
Posts: 8
Automation with C++ (Compile OK but Errors in Linking)

I was trying to compile the example code of the article about Automation of Mappoint with C/C++ http://www.mp2kmag.com/a122--c-c++.a....mappoint.html
and i manage to compile it, but when i do the "Build MapPointApp.exe" Microsoft Visual C++ gives me lots of errors like this:
Code:
Linking...
MapPointApp.obj : error LNK2001: unresolved external symbol "public: long __thiscall MapPoint::_Application::Quit(void)" (?Quit@_Application@MapPoint@@QAEJXZ)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::_Map::PutSaved(short)" (?PutSaved@_Map@MapPoint@@QAEXF@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: long __thiscall MapPoint::Pushpin::Delete(void)" (?Delete@Pushpin@MapPoint@@QAEJXZ)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: long __thiscall MapPoint::_Map::SaveAs(class _bstr_t,enum MapPoint::GeoSaveFormat,short)" (?SaveAs@_Map@MapPoint@@QAEJV_bstr_t@@W4GeoSaveFormat@2@F@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: long __thiscall MapPoint::_Map::ZoomIn(void)" (?ZoomIn@_Map@MapPoint@@QAEJXZ)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: long __thiscall MapPoint::Location::GoTo(void)" (?GoTo@Location@MapPoint@@QAEJXZ)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::Pushpin::PutHighlight(short)" (?PutHighlight@Pushpin@MapPoint@@QAEXF@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::Pushpin::PutBalloonState(enum MapPoint::GeoBalloonState)" (?PutBalloonState@Pushpin@MapPoint@@QAEXW4GeoBalloonState@2@@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::Pushpin::PutSymbol(short)" (?PutSymbol@Pushpin@MapPoint@@QAEXF@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: class _com_ptr_t<class _com_IIID<struct MapPoint::Pushpin,&struct __s_GUID _GUID_34b0f619_37e1_4c76_a6da_69bf75a5d3de> > __thiscall MapPoint::_Map::AddPushpin(struct MapPoint::Loca
tion *,class _bstr_t)" (?AddPushpin@_Map@MapPoint@@QAE?AV?$_com_ptr_t@V?$_com_IIID@UPushpin@MapPoint@@$1?_GUID_34b0f619_37e1_4c76_a6da_69bf75a5d3de@@3U__s_GUID@@A@@@@PAULocation@2@V_bstr_t@@@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: class _com_ptr_t<class _com_IIID<struct IDispatch,&struct __s_GUID _GUID_00020400_0000_0000_c000_000000000046> > __thiscall MapPoint::FindResults::GetItem(struct tagVARIANT *)" (?G
etItem@FindResults@MapPoint@@QAE?AV?$_com_ptr_t@V?$_com_IIID@UIDispatch@@$1?_GUID_00020400_0000_0000_c000_000000000046@@3U__s_GUID@@A@@@@PAUtagVARIANT@@@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: class _com_ptr_t<class _com_IIID<struct MapPoint::FindResults,&struct __s_GUID _GUID_188084cf_db96_482b_97a6_2571df9bef81> > __thiscall MapPoint::_Map::FindAddressResults(class _bs
tr_t,class _bstr_t,class _bstr_t,class _bstr_t,class _bstr_t,class _variant_t const &)" (?FindAddressResults@_Map@MapPoint@@QAE?AV?$_com_ptr_t@V?$_com_IIID@UFindResults@MapPoint@@$1?_GUID_188084cf_db96_482b_97a6_2571df9bef81@@3U__s_GUID@@A@@@@V_bstr
_t@@0000ABV_variant_t@@@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: class _com_ptr_t<class _com_IIID<struct MapPoint::_Map,&struct __s_GUID _GUID_90b167c0_923d_4b65_aee2_66938491c916> > __thiscall MapPoint::_Application::GetActiveMap(void)" (?GetAc
tiveMap@_Application@MapPoint@@QAE?AV?$_com_ptr_t@V?$_com_IIID@U_Map@MapPoint@@$1?_GUID_90b167c0_923d_4b65_aee2_66938491c916@@3U__s_GUID@@A@@@@XZ)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::_Application::PutUnits(enum MapPoint::GeoUnits)" (?PutUnits@_Application@MapPoint@@QAEXW4GeoUnits@2@@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::_Application::PutCaption(class _bstr_t)" (?PutCaption@_Application@MapPoint@@QAEXV_bstr_t@@@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::_Application::PutWindowState(enum MapPoint::GeoWindowState)" (?PutWindowState@_Application@MapPoint@@QAEXW4GeoWindowState@2@@Z)
MapPointApp.obj : error LNK2001: unresolved external symbol "public: void __thiscall MapPoint::_Application::PutVisible(short)" (?PutVisible@_Application@MapPoint@@QAEXF@Z)
Debug/MapPointApp.exe : fatal error LNK1120: 17 unresolved externals
Error executing link.exe.

MapPointApp.exe - 18 error(s), 0 warning(s)
Please, can anyone help me? I know if i get this code to work i could do my own but damn Murphy's Law, DAMN IT!!
Reply With Quote