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!

Jon
Posts: 42
Joined: Tue Jan 14, 2014 4:26 pm

Registry data fail to update when value already exists

Here is the scenario:
under Registry page, create a value "Test" with data of say, 1. See screenshot attached.
When I run the installer, if the value (Test) already exists on the PC, it will not replace the data for the value.
For example, if the PC already has Test with value of 0, after installation, it's still 0 instead of 1.
Is this a bug? I've sent you a sample AIP Project to your support email for this case for your investigation.
Attachments
registryPageSample.jpg
registryPageSample.jpg (25.07 KiB) Viewed 4493 times
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Registry data fail to update when value already exists

Hello Jon,

I'm not sure why you encountered this behavior. I've tested your scenario using the latest version of Advanced Installer and it worked as expected. An existing value from the target machine has been successfully updated. Also, in the log file of the installation process you can see that the update process worked as expected:

Code: Select all

MSI (s) (70:D8) [18:46:23:545]: Executing op: RegOpenKey(Root=-1,Key=Software\Existing_Registry,,BinaryType=0,,)
MSI (s) (70:D8) [18:46:23:569]: Executing op: RegAddValue(Name=Test,Value=#1,)
WriteRegistryValues: Key: \Software\Existing_Registry, Name: Test, Value: #1
So, can you please try to test your installation package on another machine and see if the behavior still persist?
If it does, can you please attach on the forum's thread a sample project which replicate this behavior so we can investigate this?

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Jon
Posts: 42
Joined: Tue Jan 14, 2014 4:26 pm

Re: Registry data fail to update when value already exists

Please use the attached AI test project to test the issue. Please try to uninstall and reinstall (even multiple times) to see if the registry data will update. I got the Preserve Key content checkbox checked. I'm not sure if this was causing the issue? I'm using this flag to keep the values to not being removed on uninstal, i.e. to preserve the values of all the entries under the key. Does it also tell the installer to NOT to modify the data?
Attachments
AI_Test.aip
(25.35 KiB) Downloaded 378 times
Jon
Posts: 42
Joined: Tue Jan 14, 2014 4:26 pm

Re: Registry data fail to update when value already exists

Forgot to mention "Create (if absent) at install" is also checked. Will this flag cause the data to not reset?
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Registry data fail to update when value already exists

Hi Jon,
I got the Preserve Key content checkbox checked.
Indeed, this is happening because you had enable the persistence option for a registry key operation.

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

Return to “Building Installers”