We are using Microsoft Visual Studio 2010 to compile ESRI ArcMap 10.0 add-ins. Generally it works without problems. But we have some PC with very high security policies. For example they have (beside other restrictions) no write access to %ProgramFiles%, %ProgramFiles(x86)%, etc. and it is not allowed to execute batch files. On this PC after building an add-in the add-in is not installed automatically. Furthermore when we try to debug the add-in the execution hangs up somewhere during startup of ArcMap.

To solve the problem and adjust our security settings we would like to understand the technique of building and installing the add-in file. Does anyone has a hint or did anyone have the same problem before?

  • I don't think that anything is written to Program Files during add-in build. Are you sure the failure is due to security settings? Addins are installed to %LOCALAPPDATA%\Esri\Desktop10.0\AssemblyCache – jon_two Nov 16 '15 at 9:45
  • You are right. I thing it's less the destination (user directory) where the add-in should be installed to but rather the process the installation is called. That's the reason why I would like to understand the technique behind. – Propper Nov 16 '15 at 10:34

When an addin is built (+installed), It gets copied C:\Users\username\Documents\ArcGIS\AddIns and the extracted files get copied into C:\Users\username\AppData\Local\ESRI\Desktop10.2\AssemblyCache directory. So the install user needs write permissions on those locations. Addins are designed in a way that a non-admin user could install them without any issue.

Before copying all the neccessary data, ESRIRegAddIn.exe located in C:\Program Files (x86)\Common Files\ArcGIS\bin\ESRIRegAddIn.exe get called with some install parameters (e.g. a batch command). I suppose you lock-downed environment prevents this call to ESRIRegAddIn.exe

  • My Addin is built into the ~\bin\Debug directory (this MS VS standard works). But after that there is done something ESRI specific (in the project file following target is imported: C:\Program Files (x86)\MSBuild\ESRI\ ESRI.ArcGIS.AddIns.targets). I know it MUST be the WAY, how the processes you described before which are defined in the mentioned target file, are executed. In my case the AddIn is neither copied to the users document path nor extracted to the assembly cache. I'm able to execute ESRIRegAddIn.exe on the command line without errors and I have write access to these directories – Propper Nov 17 '15 at 14:47
  • does your *.esriAddin file get created in ~\bin\Debug? if so, what happends if you install the addin manually? – Farid Cheraghi Nov 17 '15 at 14:53
  • yes it is created and I can install it manually. – Propper Nov 18 '15 at 6:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.