What does this line of script mean?

0

Issue

I have the following line of code in a batch(.bat) file that I have to run:

"c:\Program Files (x86)\Common Files\ArcGIS\bin\ESRIRegAsm.exe" /p:desktop MfeArcGis10.UI.dll

When I run this batch file, the ESRIRegAsm.exe is executed but I get the following error:

enter image description here

Can someone explain what this batch script is doing. From what I understand it is executing the executable with two arguments, however I do not know what the first argument means. Also what does the given error mean? How would I fix it?

Solution

First, take a look at Calling esriRegasm manually (outside an ArcGIS-installation).

It looks like MfeArcGis10.UI.dll is a plugin / dynamic linked library (DLL). It is necessary to register components/classes of this DLL in Windows registry under HKEY_LOCAL_MACHINE for usage by ArcGIS. This registry key requires administrator privileges for write access.

So you need to right click on this batch file and click in context menu on Run as Administrator, enter the password for the administrator account, and then the registration process should work.

Note: The batch file must be in same directory as file MfeArcGis10.UI.dll or ESRIRegAsm.exe will not be able to find the plugin file containing the information which must be added to Windows registry.

More useful pages How to register COM components containing also a link to ESRIRegAsm utility. The last page explains option /p:.

Answered By – Mofi

This Answer collected from stackoverflow, is licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0

Leave A Reply

Your email address will not be published.

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Accept Read More