We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

ronwojnar
Posts: 1
Joined: Fri Mar 04, 2016 3:52 pm

Setting a registry value, installing a package then clearing the value

Folks,

I've got a package that, due to several compatibility reasons, I need to set the RemappedElevatedProxiesPolicy to 0, install the application, then either clear/delete the registry value, or set it to 0. I've looked high and low, but can't seem to find a way to make this happen. Any advice?
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Setting a registry value, installing a package then clearing the value

Hello and welcome to Advanced Installer forums,

In order to implement your scenario you can create a custom action that will set the RemappedElevatedProxiesPolicy registry at the begining of the installation and another custom action to remove the registry key at the end of the installation.

For example, you can set the registry at the beginning of the installation, even before the Searches stage from the Wizard Dialogs Stage. The custom action that will remove the registry needs to be added after the Finish Execution stage. Note that you may need to enable the Run as administrator option from the Install Parameters page since you will make changes that requires administrative privileges.

Please take a look on the How to integrate and debug custom actions? article which may be useful to you. Using the C# custom action approach you can take advantage of the RegistryKey Class.

Should there be any difficulty you encounter implementing something, please do not hesitate to contact me and I will gladly assist.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”