Community of VE/MapPoint Users and Developers
This is a discussion on Server Busy within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Does anyone know if there is an equivalent call to App.OleRequestPendingTimeout = TimeInMiliseconds for VBA....
| |||||||
| Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| server busy
I got the "Server Busy" error saying "This action could not be completed because (my app) is not responding". My C++ .NET app was processing an input file of GPS points. The error went away when I added some well placed "axMappointControl1->MousePointer;" lines in the loop. |
| |||
| server busy error solution
Hi In .NET you can try Private Sub KillMapPointProcess() Dim proc As New Process Dim procs As Process() Dim i As Integer procs = proc.GetProcessesByName("MapPoint") If procs.Length = 0 Then Return 'MP wasn't loaded, so return For i = 0 To UBound(procs) procs(i).Kill() procs(i).WaitForExit() Next End Sub In VB6 I had the same problem until I closed ALL objects with = NOTHING Since then no problems anymore Wim |
| |||
| Visual C++, Server Busy, Switch To...
Hi, I have a VC++ project and embedded MapPoint as an ActiveX in a Dialog-Box. When I let MapPoint calculate a route between 2 points that are close to each other... everything works fine. As soon as I try a route between 2 points that are far away from each other -> the calculation takes more than 20 seconds (!!) and after that a "Server Busy, Switch To..." dialog is popping up. I tried all the things from http://support.microsoft.com/default...b;EN-US;248019 But still I have the problem... Did anybody solve this in VC++ ? Thanks Gustav |
| |||
| VC++
What I used to do when using MapPoint with C++ was to post a custom message to the parent window, when MapPoint fired an event. Then I would handle the custom message accordingly. i.e. If I wanted to calculate a route after the user has clicked a second spot on the map, I get the SelectionChanged event from MapPoint (or whatever the event is called, I forget). Then I post my own custom message (say WM_USER) to the control's parent window. Then on the handler for WM_USER, I have it calculate the route. MapPoint only seems to complain if you take too long handling an event that it launched. So by posting another event, and letting the MapPoint event terminate, it's happy. In C# now, I just have a timer (too lazy to play with posting messages) that I set to 50ms from a MapPoint event. Then the timer triggers the code I want to fire when as a result of the Map event. I hope this makes sense. Joel |
| |||
|
Hey Joel, Thanks a lot. I tried the "timer thing" - a possible solution you described. And it works! No more "Server Busy"-Dialogs!!! It really seems that MapPoint wants to terminate its own events quickly! Cool! Thank you. Gustav |
| |||
|
Looks like Joel has the answer to the VBA code problem. What you want to do when handling events like: Code: Private Sub MPC_SelectionChange(ByVal pNewSelection As Object, ByVal pOldSelection As Object) His solution is the only way I know how to do it: set a timer. Timers fire after the current procedure has finished executing, or upon a "DoEvents." You will find this technique useful for a lot of other reasons, so I suggest that you set up your timer event to handle a variety of procedures. To do this, declare a public variable for your form that can be accessed from outside the form. Let's say that the form that contains the MapPoint control is called "MapForm." Declare a public variable at the top of the MapForm code, like Code: Public TimerProc as String Code: Private Sub MPC_SelectionChange(ByVal pNewSelection As Object, ByVal pOldSelection As Object) TimerProc = "SelectionChange" TimerInterval=1 End Sub Code: Select Case TimerProc Case "SelectionChange" <insert the code the handle the SelectionChange event here> Case "MouseUp" <insert the code the handle the MouseUp event here> Case "ProcThatMustBeRunFromThisFormModuleButYouWantToCallfromOutside" <use the DoEvents command to get this code to run in-line from an external procedure. The TimerProc variable is referenced as MapForm.TimerProc> End Select |
![]() |
| Tags |
| busy, server |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Server is Busy | Anonymous | MapPoint 2006/2009 Discussion | 4 | 01-18-2005 04:52 AM |
| server busy problem! | Anonymous | MapPoint 2006/2009 Discussion | 8 | 01-02-2005 04:04 AM |
| Timer and Server Busy | Anonymous | MapPoint 2006/2009 Discussion | 0 | 07-07-2004 03:59 AM |
| Server Busy Message fix in .Net | matnace | MapPoint 2006/2009 Discussion | 0 | 05-11-2004 12:48 PM |
| Server busy ... svchost is 99% CPU | Anonymous | MapPoint 2006/2009 Discussion | 1 | 10-17-2003 08:42 AM |