MapViewer Automation Errors

A list of errors sometimes seen with MapViewer automation is provided below. Click the error message you're seeing to view information about resolving the error.


 "ActiveX Automation: no such property or method" or "ActiveX Automation: no such named parameter"

This error is usually caused by a typo in one of the properties or method in the line indicated by the error. For example, this line would generate that error:


This is because there is a typo in the method. The method "Cell" should be "Cells", as seen in the WksRange object properties and methods.


If there are no typos in the line, this error could also be caused by using new properties or methods with an older version of MapViewer. For example, this line would generate that error when run in MapViewer 7:

Proj.ProjectionType = mvProjNewZealandMapGrid

This is because the mvProjNewZealandMapGrid value for the MapFrame property was added in MapViewer 8. There is no such property or method in MapViewer 7 (or prior).


If you are certain the line doesn't contain typos and is supported by the version of MapViewer you are using, please email a simplified script that can be run in Scripter that exemplifies the problem to


"ActiveX Automation: Server Could Not Be Found" or "ActiveX Automation: Server Cannot Create Object"

The (10096) ActiveX Automation: server could not be found error and the ActiveX Automation: server cannot create object error typically occur when MapViewer and/or Scripter are not properly registered on the computer. When the programs are not registered properly on the computer, it is usually an indication that the programs have not been run interactively, that lack of user permissions are preventing the proper registry items from being created, that multiple versions of MapViewer are installed on the computer and are interfering with registry item creation, or that MapViewer was installed improperly to a network location.


First, be sure that MapViewer was installed either directly on the workstation it is being called from, or from the workstation to a network location. If it was installed directly on the network server, it cannot be called via automation from a workstation because the necessary registry items are not created on the workstation. If this is the case, you will need to talk to your IT personnel to get MapViewer installed on your local workstation so you can call it via automation.


Second, check to be sure MapViewer was opened prior to trying to access it via automation. MapViewer must be opened interactively at least once in administrator mode prior to calling it via a script. Please try these steps:

  1. Right-click the MapViewer icon or EXE file.
  2. Click Run as administrator.
  3. Close MapViewer.
  4. Right-click the Scripter icon or EXE file.
  5. Click Run as administrator.
  6. Close Scripter.
  7. Then try running the script.


If you still get the error, please make sure there is only one version of MapViewer installed on the computer, then repair the installation. To do this:

  1. Log on to the computer as an administrator.
  2. If MapViewer or Scripter is open, close the program.
  3. Navigate to the Windows Control Panel and click Uninstall a program.
  4. In the Uninstall or change a program window, uninstall any other older versions of MapViewer, including the demo versions, that are installed on the computer (if any). If no other version of MapViewer is installed on the computer, skip this step.
  5. Repair the current MapViewer installation by selecting it, clicking Change, selecting Repair and clicking Next. The installer will run the repair.
  6. When the installer is finished, check the option to run MapViewer now and click Finish.
  7. After MapViewer opens, close the program.
  8. Try running the script now.


If you still get the message, you can try manually registering MapViewer before attempting to run the script. To do this:

  1. Close Scripter and MapViewer.
  2. Click the Windows Start button.
  3. In the search box (which is also the Run command), enter the path to the map.exe file in quotes followed by /register. For example: "C:\Program Files\Golden Software\MapViewer 8\map.exe" /register.  Be sure to include the quotation marks, and be sure the path to map.exe goes to wherever MapViewer is installed, if it was not installed to the default directory.
  4. Press ENTER on the keyboard. If the command is successful, it will appear as if nothing happened.
  5. Now re-run MapViewer and Scripter as administrator. Right-click the MapViewer icon or EXE file.
  6. Click Run as administrator.
  7. Close MapViewer.
  8. Right-click the Scripter icon or EXE file.
  9. Click Run as administrator.
  10. Close Scripter.
  11. Try running the script now.


If both MapViewer and Scripter (or whatever program you are using to call MapViewer) are set to run as administrator and you still get the error, other reasons could include:

  1. There is a problem running MapViewer when PC Anywhere runs at startup.  If you are running PC Anywhere, you can work around the problem by removing PC Anywhere from the startup menu, restart the computer and then starting PC Anywhere manually after the computer restarted. 
  2. If that also doesn’t help, you can try turning the UAC (User Account Control) off via the Control Panel | User Accounts. You will need to reboot after UAC is turned off.


If you still get the error, please send an email to with the version of MapViewer you are using (File | About MapViewer), your serial number or product key and the steps you have tried (above).


"ActiveX Automation: No Object Currently Active"

This error means that the script calls a currently active instance of MapViewer and it can’t find one. For example, the script begins with:

Set MVAppGetObject(, "MapViewer.Application")


The “GetObject” command calls a currently open instance of MapViewer. If there is no MapViewer window open, then the error is generated. You can either open MapViewer first and then run the script, or you can change the script to create a new instance of MapViewer instead of getting an existing instance:

Set MVApp = CreateObject("MapViewer.Application")


The code below can also be used to check for an open instance of MapViewerand if one is not found open a new instance.

Function MapViewerApplication() 
On Error Resume Next
Set MapViewerApplication = GetObject( ,"MapViewer.Application")
If Err.Number <> 0 Then
Set MapViewerApplication = CreateObject("MapViewer.Application")
End If
On Error GoTo 0
End Function

Sub Main

'Define the Mapviewer application object and create a new plot

Dim MVApp As Object
Set MVApp = MapViewerApplication()


 "Unable to open <file path>"

If you're running a script where you've defined your file name and file path as a single variable (i.e. file$ = "c:\temp\filename.dat"), make sure that the file exists in that directory, and there are no typos. Neither the name nor the path are case-sensitive.


If you're running a script where you've defined your file name and file path as two separate variables (i.e. filepath$ = "c:\temp\" and filename$ = "filename.dat"), the above could still be the issue, but another cause could be forgetting the slash at the end of the file path. If this has happened to you more than once, I suggest adding the following line to your script, after defining the file name and file path variables, but before using them:

If Right(filepath$,Len(filepath$)-(InStrRev(filepath$,"\")-1))<>"\" Then filepath$=filepath$+"\"

This checks the end of the file path for the \ character, and adds it if it doesn't find it. 


Related Articles:


Updated: February 4, 2019

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request


Please sign in to leave a comment.