I would like to know if I can use DAML to
I wrote an Add-In that is replacing two earlier Add-Ins I wrote and I would like to delete the two earlier Add-Ins on a customers AGP if they are installed.
Is that possible during the installation process of the new Add-In?
Solved! Go to Solution.
You can use this method to iterate through all add-ins and find your old add-ins, then use FullPath to delete the add-in (will disappear after ArcGIS Pro restarts): GetAddInInfos Method—ArcGIS Pro
Needless to say, this only works if the user has permissions to delete the add-in.
You can also look at this sample code which deletes add-ins: Esri/arcgis-pro-sdk-community-samples: ArcGIS Pro SDK for Microsoft .NET Framework Community Samples...
Hi,
If you know old add-ins GUID's you can remove their folders from This PC > Documents > ArcGIS > AddIns > ArcGISPro folder.
<AddInInfo id="{997969c2-c517-4481-af7e-dbdb0e20399c}" version="1.0" desktopVersion="2.0.0">
<Name>Custom Pop-up Tool</Name>
<Description>Show a custom pop-up.</Description>
<Image>Images\AddinDesktop32.png</Image>
<Author>ArcGIS Pro SDK Team, arcgisprosdk@esri.com</Author>
<Company>esri, http://www.esri.com</Company>
<Date>9/28/2015</Date>
<Subject>Map-Exploration</Subject>
</AddInInfo>
I know the GUIDs. However, that does not sound like this is something I can build into to installation routine of the new Add-In.
I am looking for some functionality similar to dependencies of one Add-In to another Add-In, or using the DAML to remove buttons in the UI... just to delete a whole Add-In.
You can build simple bat file with OS commands or code executable using c#.
Another way is to use configuration instead of add-in. It could remove add-in commands/tools from ArcGIS Pro UI. Check configuration samples on Esri Community samples git.
You can use this method to iterate through all add-ins and find your old add-ins, then use FullPath to delete the add-in (will disappear after ArcGIS Pro restarts): GetAddInInfos Method—ArcGIS Pro
Needless to say, this only works if the user has permissions to delete the add-in.
You can also look at this sample code which deletes add-ins: Esri/arcgis-pro-sdk-community-samples: ArcGIS Pro SDK for Microsoft .NET Framework Community Samples...
Thank you Wolf, that's a clean solution.