| | |
C++ Builder and Mappoint Pushpins Problem
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Apr 2004
Posts: 2
Reputation:
Solved Threads: 0
I am trying to get the Microsoft Mappoint OCX working in C++ Builder 6.0 Pro.
So far I can place pushpins and delete them but I cannot attach a name or note.
When the compiler is in Debug mode the code will compile without any error but crashes when running Mappoint related code.
It reports - Debugger Exception Notification
Project MapTest2.exe raised exceptionclas EAccessViolation with message 'Access violationat address 00401DD3 in module 'MapTest2.exe.
Reda of address 00000000'. Process stopped. Use Step or Run to continue.
It would appear that the C++ cannot handle the Microsoft Mappoint OCX properly - all suggestions welcome.
When the complier is in Release mode the code works.
:rolleyes:
So far I can place pushpins and delete them but I cannot attach a name or note.
When the compiler is in Debug mode the code will compile without any error but crashes when running Mappoint related code.
It reports - Debugger Exception Notification
Project MapTest2.exe raised exceptionclas EAccessViolation with message 'Access violationat address 00401DD3 in module 'MapTest2.exe.
Reda of address 00000000'. Process stopped. Use Step or Run to continue.
It would appear that the C++ cannot handle the Microsoft Mappoint OCX properly - all suggestions welcome.
When the complier is in Release mode the code works.
:rolleyes:
Last edited by Trevor@Taran; Apr 20th, 2004 at 5:48 am. Reason: additional information added
•
•
Join Date: Jul 2004
Posts: 1
Reputation:
Solved Threads: 0
Hello Trevor!
I am trying the same thing with CB5 but it only works to add a pushpin - not to delete them. Can you tell me how you've been able to delete all the pushpins you've made in your program???
Here is a sample code how I make pushpins in my Application including a note and a symbol:
void __fastcall TForm1::AddPin( double Lat, double Lon, AnsiString
Truck, AnsiString Note )
{
WideString txt;
PushpinPtr pin;
LocationPtr loc;
loc = Map->GetLocation( Lat, Lon, 100 );
txt = Truck;
pin = Map->AddPushpin( loc, txt );
pin->set_BalloonState( geoDisplayName );
pin->set_Symbol( 85 );
pin->set_Highlight( true );
txt = Note;
pin->set_Note( txt );
pin->MoveTo( TruckSet );
delete pin;
delete loc;
}
Hope you can help me!
Thanks in Advance,
Michi
I am trying the same thing with CB5 but it only works to add a pushpin - not to delete them. Can you tell me how you've been able to delete all the pushpins you've made in your program???
Here is a sample code how I make pushpins in my Application including a note and a symbol:
void __fastcall TForm1::AddPin( double Lat, double Lon, AnsiString
Truck, AnsiString Note )
{
WideString txt;
PushpinPtr pin;
LocationPtr loc;
loc = Map->GetLocation( Lat, Lon, 100 );
txt = Truck;
pin = Map->AddPushpin( loc, txt );
pin->set_BalloonState( geoDisplayName );
pin->set_Symbol( 85 );
pin->set_Highlight( true );
txt = Note;
pin->set_Note( txt );
pin->MoveTo( TruckSet );
delete pin;
delete loc;
}
Hope you can help me!
Thanks in Advance,
Michi
•
•
Join Date: Apr 2004
Posts: 2
Reputation:
Solved Threads: 0
Hi Michi,
I have already posted a reply in the private messages forum but the following is more or less what I said.
I have a solution to interfacing Borland Builder and Mappoint but I am using it in a tracking system. Can you tell me what you are using it for - ie are you a competitor??.
Deleting a pin is as simple as pin->delete but you will have many more hurtles to get over before you get it all working the way you want it. Email me and I will sned you a CD with our software on it (no source) then you can see what I have done.
Regards,
Trevor
I have already posted a reply in the private messages forum but the following is more or less what I said.
I have a solution to interfacing Borland Builder and Mappoint but I am using it in a tracking system. Can you tell me what you are using it for - ie are you a competitor??.
Deleting a pin is as simple as pin->delete but you will have many more hurtles to get over before you get it all working the way you want it. Email me and I will sned you a CD with our software on it (no source) then you can see what I have done.
Regards,
Trevor
•
•
•
•
Originally Posted by comtecworks
Hello Trevor!
I am trying the same thing with CB5 but it only works to add a pushpin - not to delete them. Can you tell me how you've been able to delete all the pushpins you've made in your program???
Here is a sample code how I make pushpins in my Application including a note and a symbol:
void __fastcall TForm1::AddPin( double Lat, double Lon, AnsiString
Truck, AnsiString Note )
{
WideString txt;
PushpinPtr pin;
LocationPtr loc;
loc = Map->GetLocation( Lat, Lon, 100 );
txt = Truck;
pin = Map->AddPushpin( loc, txt );
pin->set_BalloonState( geoDisplayName );
pin->set_Symbol( 85 );
pin->set_Highlight( true );
txt = Note;
pin->set_Note( txt );
pin->MoveTo( TruckSet );
delete pin;
delete loc;
}
Hope you can help me!
Thanks in Advance,
Michi
![]() |
Similar Threads
- Builder cpp 6 - resources problem (C++)
- Borland C++ Builder 6 Errors (C++)
- Access Violation (C)
- ?A Simple Win32 GUI Introduction Snippet? (C++)
- Bug when creating linked lists in Dev C++ (C++)
- Better code for TCheckListBox (C++)
Other Threads in the C++ Forum
- Previous Thread: Running a program
- Next Thread: RAW Packet Forwarding
| Thread Tools | Search this Thread |
Tag cloud for C++
api application array arrays based beginner binary bmp c++ c/c++ calculator char char* class classes code compile compiler console conversion convert count data delete deploy dll download dynamiccharacterarray email encryption error file format forms fstream function functions game givemetehcodez graph homeworkhelp iamthwee ifstream input int java lib library lines list loop looping loops map math matrix memory newbie news number numbertoword output pointer problem program programming project python random read recursion recursive reference return rpg search simple sorting spoonfeeding string strings struct temperature template templates text text-file tree url variable vector video visual visualstudio void win32 windows winsock wordfrequency wxwidgets




