loading error

alxster
01-09-2008, 10:12 AM
I am completely newbie in MapPoint and I am trying to use its ocx (Mappoint 2006) in a Delphi 7 application (i modified ole sources as in http://www.mapforums.com/got-mappoint-activex-working-delphi-5-a-1973.html)

but now, whenever i try to open a map with

map: TMappointControl;
..............
map.NewMap(geoMapEurope);
it gives me an EOleException with the following error message (translated from italian):
Unknown Error. Impossible loading Mappoint

(Original in italian: Errore sconosciuto. Impossibile caricare MapPoint)

i tried the same in VB 2005 Express Edition

AxMappointControl1.NewMap(MapPoint.GeoMapRegion.ge oMapEurope)and

i get a

System.Runtime.InteropServices.COMException occurred in AxInterop.MapPoint.dllwith same error message and errorcode = -2147221163

it is like if it is not able to "launch" mappoint instance... maybe i have to set any configuration tip?

thanks in advance

Wilfried
01-10-2008, 01:10 PM
Hi,

I assume mappoint.exe if you try to run is running normal ?
try to register the exe. with typing: mappoint.exe /registerserver

alxster
01-10-2008, 03:56 PM
I assume mappoint.exe if you try to run is running normal ?yes

try to register the exe. with typing: mappoint.exe /registerserver

so, yes, I already tried this... before posting...

Wilfried
01-16-2008, 05:52 AM
Hi,

I have no idea. I never tryed it and only use the object model in Delphi. However the thread shows someone who done it also in Delphi7, so it should work. Maybe you have installed the update packs and he did not or way around ?

alxster
01-16-2008, 09:53 AM
so, i found how to solve the problem, just with dos command "regsrv32 ole32.dll"

of course troubles are not finished, because now, it do not give me any error but... just map remain blank, i mean not blank without pushpin etc. i mean the mappoint control shows a empty blank rectangle without any map!!!

i tried to log the ReadyStateChange event and this is the sequence of state changed:

READYSTATE_UNINITIALIZED
READYSTATE_INTERACTIVE
READYSTATE_COMPLETE

so, i think there should be some

READYSTATE_LOADING
and
READYSTATE_LOADED

maybe is there something that goes wrong?

i tried also on vb and c# (2005 express editio) and also in c# by calling EndInit() method of mappoint control.... same result...

 
Web mp2kmag.com
mapforums.com