Community of MapPoint and Bing Maps Users and Developers
This is a discussion on MapPoint 2006 ActiveX with new Form within the MapPoint Desktop Discussion forums, part of the Map Forums category; Hi there, same probleme again. I included the MapPoint Control 13.0 in a Visual Studio Project, made a Button on ...
| |||||||
| Today's Posts | Twitter Feed | Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| same probleme again. I included the MapPoint Control 13.0 in a Visual Studio Project, made a Button on my Form and did this: Form myForm = new Form(); AxMappointControl mapPoint = new AxMappointControl(); myForm.Controls.Add(mapPoint); mapPoint.NewMap(MapPoint.GeoMapRegion.geoMapEurope ); myForm.Show(); On Line mapPoint.NewMap(...) i get System.Windows.Forms.AxHost+InvalidActiveXStateExc eption if i try this: Form myForm = new Form(); myForm.Show(); AxMappointControl mapPoint = new AxMappointControl(); myForm.Controls.Add(mapPoint); mapPoint.NewMap(MapPoint.GeoMapRegion.geoMapEurope ); everything works fine Where is the probleme? |
| |||
| Re: MapPoint 2006 ActiveX with new Form
Hi there, no, i won't write "I got the solution, thanks, bye". The problem was that the activeX wasn't completly initialized, in which way ever the show method of the form called the EndInit() Method of the ActiveX and made the usage afterwards possible. Solution: Just call it yourself. Form myForm = new Form(); AxMappointControl mapPoint = new AxMappointControl(); myForm.Controls.Add(mapPoint); mapPoint.EndInit(); // <- That's the way mapPoint.NewMap(MapPoint.GeoMapRegion.geoMapEurope ); myForm.Show(); Sry for my bad and irritating english, i'm german an not quite used to write or talk in english. Hope this helps some of you. Give me some hinds if the problem was totally clear and i'm just dumb ^^ |
![]() |
| Tags |
| activex, form, mappoint 2006 |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Mappoint and Access with ActiveX On A Form | jpateusa | MapPoint Desktop Discussion | 5 | 05-16-2009 06:32 PM |
| MapPoint 2006 with ActiveX | jasanite | MapPoint Desktop Discussion | 4 | 08-10-2007 10:05 AM |
| VC++ doesn't find MapPoint 2006 ActiveX control | DrNobody | MapPoint Desktop Discussion | 3 | 02-22-2007 09:41 AM |
| Mappoint 2006 ActiveX Questions | ben_dillon | MapPoint Desktop Discussion | 3 | 01-31-2007 06:16 AM |
| mapPoint 2006 activex control slow down form closing | bule | MapPoint Desktop Discussion | 1 | 09-26-2006 01:22 PM |