Random not ready errors

ToddRCS
11-14-2002, 08:34 AM
I am using the MapPoint 2002 ActiveX control in a Microsoft Access 2000 application using VBA. I am having a problem getting runtime errors randomly in parts of the code that reference a MapPoint object or function. The error says that the object or function is not available. It seems that the map is not ready to perform the requested function or that an object that should be there is not at the time it is referenced.

Has anyone experienced a similar problem with MapPoint. Any suggestions as to a solution to eliminate these errors would be appreciated. Thanks.

John Meyer
11-14-2002, 12:18 PM
Based on your statment "seems that the map is not ready to perform the requested function" maybe you can test the ReadyState before you execute the code that is giving you the error?

if MappointControl1.ReadyState = READYSTATE_COMPLETE then

ToddRCS
11-14-2002, 02:08 PM
Thanks for the suggestion, John.

I tried this solution already. It greatly reduced the occurrences of the errors, however, once in a while the error still happened.

(Recently I removed this check of the ready state to try and repeat the errors more frequently, and now I can't get it to repeat any of the errors at all. Not sure if this is good or not.)

John Meyer
11-14-2002, 06:31 PM
Is there or was there some process that is using alot of CPU time or causing alot of disk access?

You might have to deal with that to allow mappoint enough resources to work right?

 
Web mp2kmag.com
mapforums.com