Welcome to the Indigo Rose Software discussion forums! You will need to sign up for a forum account and login before you can post. Need help? View the Forum FAQ.
I need to set a variable based on if a "Value Name" exists (not the key, which is a feature of SF6). Any ideas? Unfortunately, the value (binary) is not readable, so I can't use something like if %value% <> FALSE.
There's probably an easier way to do this that is more integral to SF6, but it eludes me at the moment (Mark?)...in any case, here's one way that would work:
Export the registry key to a .reg file, and then (using string actions) parse the file to determine the presence of that value.
Tip: use regedit's /e arg (or /a in 2k/XP), along with the /s arg to make it run silently...
I think Lorne's right, it wouldn't be that hard either, simply export the registry key to a temporary directory. Then read the information from the file into a variable using a Read Text File action. Once have done that simply use a Find String action to search the variable for the Value you are looking for.
You action list would look something like this:
Execute Program (Regedit.exe) (pass it something like: /s /ea %TempDir%\Reg.txt "HKEY_CURRENT_USER\Software\Microsoft\Internet Account Manager\Accounts")
Read Text File (%RegFile% = Contents of %TempDir%\Reg.txt
Find String (%Value% = position of ValueName in %RegFile%)
mark.
MSI Factory The Next Generation Intelligent Setup Builder
Comment