Dev
Posts: 17
Joined: Mon Oct 06, 2008 6:55 am

Properties Coming Up Empty

I'm trying to set registry permissions differently based on OS (ASPNet vs. Network Service), so I'm following the guidance in http://www.advancedinstaller.com/forums ... 37&p=10492 (2nd post) to do a Property Set With Formatted from installUISequence-->CostFinalize (also tried -->Begin). This part seems to be working properly, and in the log I see it correctly determining which user I want to use (in this case, Network Service):
MSI (c) (24:9C) [01:26:44:224]: PROPERTY CHANGE: Adding IISAccountForRegistryACLs property. Its value is 'NETWORK SERVICE'.
So first I tried setting the registry permissions in the Project Definition --> Registry --> Properties --> Permissions, entering [IISAccountForRegistryACLs] for the username, but received the following in the log, and the user in the actual regisry ACl was set to builtin\builtin and shows an error icon.
WriteRegistryValues: Key: Writing system registry values, Name: , Value:
MSI (s) (58:DC) [00:57:53:183]: SID WARNING: User account '[IISAccountForRegistryACLs]' resolved to an empty string!
So next, as a workaround I've tried an InstallExecuteSequence-->InstallFinalize custom action (file attached to installation) using SetACL.exe (several other support responses incorrectly indicate to use XCACLs.exe, but that only works for files not registry) the property is still coming up empty. The following is the command line of the custom action:
-on "HKEY_LOCAL_MACHINE\SOFTWARE\comapny\product" -ot reg -actn ace -ace "n:[IISAccountForRegistryACLs];p:full"
And in the resulting install log (note the property is not resolving to anything):
Action start 2:11:25: SetACL.exe.
MSI (s) (40:78) [02:11:26:855]: Note: 1: 1722 2: SetACL.exe 3: C:\Windows\Installer\MSIC270.tmp 4: -on "HKEY_LOCAL_MACHINE\SOFTWARE\company\product" -ot reg -actn ace -ace "n:;p:full"
What am I doing wrong? How do I get the property to show up?
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: Properties Coming Up Empty

Hi,

Please note that private properties cannot pass their values from the UI Sequence (when the dialogs are shown) to the Execute Sequence (when the install process is running). Therefore, you can use a public property for the user account.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Dev
Posts: 17
Joined: Mon Oct 06, 2008 6:55 am

Re: Properties Coming Up Empty

Thank you. This is working now.

I have to admit that is the easiest fix ever - simply change the property name to all caps.

Return to “Common Problems”