Community of MapPoint and Bing Maps Users and Developers
This is a discussion on About ERROR 4-40028-1. Error or Bug ? within the MapPoint Desktop Discussion forums, part of the Map Forums category; Hi I have just found that this error is thrown also when : I have 2 coordinates : p1(lat1,long1) p2(lat2,long2) ...
| |||||||
| Today's Posts | Twitter Feed | Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| About ERROR 4-40028-1. Error or Bug ? I have just found that this error is thrown also when : I have 2 coordinates : p1(lat1,long1) p2(lat2,long2) When we add the 2 points on a map, here are the possible errors : (E1) IF lat1==lat2 AND long1==long2 THEN ERROR 4-40028-1 (E2) IF lat1==lat2 AND long1<>long2 THEN ERROR 4-40028-1 The second case (E2) is very problematic to me because we have an application tracking vehicles and sometimes between 2 coordinates the latitude is the same but not the longitude... To me it's a bug... What do you think of this ? |
| |||
|
Hi, Just putted 2 pushpin on map with same latitude and different longitude. Then connected them with an arrow. No exception, no error... Where comes this error out ? Can you demonstrate the behavour with a few lines of code ?
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz www.comfortsoftware.be MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
| |||
|
Hi Do you use MapPoint 2002 ? With my version of MapPoint Europe 2002, I have a list of coodinates. In this list there is the following points : LAT[0x17] = 48.4537363 LONG[0x17] = 2.0505554 LAT[0x18] = 48.4537359 LONG[0x18] = 2.0505554 Here's the drawing source code : The error seems to happen in the "zoomout" functions. Also, I tried to cancel the zoomout functions but the error still happens. When I remove the 2 GPS coordinates LAT[0x17] LONG[0x17] and LAT[0x18] LONG[0x18] the error does not happen... private void TraceTrackPoints() { try { // Gets a reference on the mappoint 2002 control MapPoint.Map mpmap = this.axMappointControl1.ActiveMap; // Geocodes all the points in array, and links them with a line shape int i=0; while ( (g_dLat[i] != -1) && (g_dLong[i] != -1) ) { mpmap = this.axMappointControl1.ActiveMap; mploc[i] = mpmap.GetLocation(g_dLat[i], g_dLong[i], 1); if(i==0) mploc[i].GoTo(); // zoom on start point MapPoint.Shape sh = null; if(i>0) { sh = mpmap.Shapes.AddLine(mploc[i-1], mploc[i]); sh.Line.Weight= 1; } MapPoint.Pushpin pp = null; if (i==0) pp = mpmap.AddPushpin(mploc[i], "START"); else pp = mpmap.AddPushpin(mploc[i], ""); pp.Symbol = 83; i++; } mpmap.ZoomOut(); mpmap.ZoomOut(); } catch(Exception) { MessageBox.Show("ERROR", "ERROR", MessageBoxButtons.OK, MessageBoxIcon.Warning); } } thanks |
| |||
|
Hi, Probably the reason I dont have the error. I use MP 2004 at the moment. I have MP 2002 also but the machine where it is on is at the moment defective motherboard. Should be repaired next week. I will try this when I have again access to that machine. In case I forget please send me ar reply to remind me
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz www.comfortsoftware.be MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
| |||
|
LAT[0x17] = 48.4537363 LONG[0x17] = 2.0505554 LAT[0x18] = 48.4537359 LONG[0x18] = 2.0505554 I have just traced my application in debug mode in VS.NET C# 2003 and the error is throw on the following line, for LAT[0x18] and LONG[0x18] sh.Line.Weight= 1; I'm sure at 99% that the error is due to the similar longitudes... Let me know if you can reproduce the same case thanks |
| |||
| Quote:
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz www.comfortsoftware.be MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
| |||
|
Hi, Just thinging on something what could be a workaround. What if you compare both latitudes, and if they are equal increment 1 by 0.00005 ? This is around 5.5 meter difference. Maybe even a smaller increment is oK to not get the error again ?
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz www.comfortsoftware.be MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
| ||||
|
As an aside, Wilfried, you can run MapPoint 2002 and 2004 on the same machine. The only problem is if you have an executable that accesses MapPoint as a COM object - then it will always default to 2004 even if you explicitly give the 2002 version number. This PC here has three versions of MapPoint installed, and the fourth is currently in the mail Richard
__________________ Winwaed Software Technology LLC http://www.winwaed.com See http://www.mapping-tools.com for MapPoint Tools See the Geoweb Guru for online mapping |
| |||
|
I seem to remember that I would run into a problem when adding a zero-length line (Lat1=Lat2 and Long1=Long2) in Mappoint 2002 (programming in VB6), but I have no way to test that now. Your two points are virtually on top of one another. Could that be your issue here? |
![]() |
| Tags |
| bug, error |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| MapPoint error 4-40028-1 : Solution | Etienne | MapPoint Desktop Discussion | 5 | 01-11-2008 05:23 AM |
| synchronous error | Wilfried | MapPoint Desktop Discussion | 4 | 06-09-2005 04:27 AM |
| Mappoint Error | Mudrover | MapPoint Desktop Discussion | 5 | 01-20-2005 02:59 PM |
| I get this following error | ananthdeena | MapPoint Desktop Discussion | 3 | 01-01-2005 02:46 AM |
| Runtime Error 462 | Anonymous | MapPoint Desktop Discussion | 0 | 09-02-2004 04:07 AM |