Execution condition problems - Advanced Installer Community

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!

cesdewar
Posts: 11
Joined: Mon Oct 20, 2008 10:27 pm

Execution condition problems

I want to launch an EXE but not if running under VISTA and UAC enabled because it won't handle the EXE file - instead I would like to just tell the user to run the EXE after the install (which works just fine).

I have the EXE set up under Custom Actions/Install and then set up a search with the variable UAC_ENABLED tied to the registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\policies\system\EnableLUA

I can run the TEST in the search pane and verify that the correct value is retrieved for this registry key.

I then included as the Execution Condition:
(VersionNT < 600) or (UAC_ENABLED = 0)

I.e. run this if not vista, OR Vista, but UAC not enabled. I even just made the test: UAC_ENABLED = 0
but the EXE file never runs. I changed the test to UAC_ENABLED ~= 0 and it still does not run - so I must be missing something as to how this mechanism works as if it is a condition, it has to work on one of them! What am I missing here?? I tried another test (for windows version) and that worked fine - just using this registry variable as a user-defined property doesn't do what I expect...

Oh, and the dialog for testing says: "the search result will apear in the edit-box"
Need two p's there, eh? :wink:
cesdewar
Posts: 11
Joined: Mon Oct 20, 2008 10:27 pm

Re: Execution condition problems

OK, I finally found the answer to my own question - the argument was not properly formed. The correct format was:
UAC_ENABLED = "#0"

I had tried using a pound sign, but didn't realize it also required the quotes around it - but it now seems to work properly!!
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: Execution condition problems

Hi,
Oh, and the dialog for testing says: "the search result will apear in the edit-box"
Need two p's there, eh?
Thank you for bringing this to our attention. We will fix it in the next version of Advanced Installer.
The correct format was:
UAC_ENABLED = "#0"
Indeed, the value of an installer property is always a string. Also, registry searches use special characters based on the type of the target registry value.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”