Change regkey value in MSI.
I have an app which needs to set:
HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon
allocatecdroms=1
However, on our client this key is already there as "0". Therefore when the MSI is run the value doesn't get changed. I know I could run a batchfile to delete the value before the install is run, but I was wandering if there is a way to remove this key in the MSI, before the key is added (with value "1)?
Thanks,
Mike.
HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon
allocatecdroms=1
However, on our client this key is already there as "0". Therefore when the MSI is run the value doesn't get changed. I know I could run a batchfile to delete the value before the install is run, but I was wandering if there is a way to remove this key in the MSI, before the key is added (with value "1)?
Thanks,
Mike.
0 Comments
[ + ] Show comments
Answers (9)
Please log in to answer
Posted by:
cygan
17 years ago
ORIGINAL: Meic
I have an app which needs to set:
HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon
allocatecdroms=1
However, on our client this key is already there as "0". Therefore when the MSI is run the value doesn't get changed. I know I could run a batchfile to delete the value before the install is run, but I was wandering if there is a way to remove this key in the MSI, before the key is added (with value "1)?
Thanks,
Mike.
not sure when you say is there a way to remove this key in the msi before the key is added ( with value "1")
but if you are saying you want to run the reg file with a value of "1"
then set the value to 1 and export the reg file into the application directory in the msi
then run the reg file with a custom action using REGEDIT/ S <c:\program files\app name\regfile.reg>
sequence after installfinalize with a condition Not Installed
what packaging tool are you using
Posted by:
cygan
17 years ago
Posted by:
Meic
17 years ago
Posted by:
AB
17 years ago
Adding a registry key in your MSI to the value you require will override any existing key value...
In your example, the 'allocatecdroms' key has a value of '0'
Your MSI should contain the same key location but with a value of '1'
When you install your MSI, the value will change - to '1'
If you then uninstall your MSI - the key will be removed
Test...
Regards,
Al
In your example, the 'allocatecdroms' key has a value of '0'
Your MSI should contain the same key location but with a value of '1'
When you install your MSI, the value will change - to '1'
If you then uninstall your MSI - the key will be removed
Test...
Regards,
Al
Posted by:
fosteky
17 years ago
Posted by:
AB
17 years ago
Thanks Kyle
Initial test - Admin - works
Secondary test - locked down - works
Thirdly- works over, lets go out and get stinking drunk
Hooray...
Registry, do do
What is it good for
Absolutely nothing
Say it again...
Regards,
Al
Plan a sense us...
Your job title is PACKAGING SPECIALIST
i'M A packagerneer
What interesting job titles have you guys and girls been given / made up?
Initial test - Admin - works
Secondary test - locked down - works
Thirdly- works over, lets go out and get stinking drunk
Hooray...
Registry, do do
What is it good for
Absolutely nothing
Say it again...
Regards,
Al
Plan a sense us...
Your job title is PACKAGING SPECIALIST
i'M A packagerneer
What interesting job titles have you guys and girls been given / made up?
Posted by:
Meic
17 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.