1

I need to give permission to a LocalSystem windows service installed with WIX to write a SQL Server CE file to CommonAppDataFolder. I'm using:

<Directory Id="CommonAppDataFolder">
    <Directory Id="CompanyNameDataFolder" Name="!(loc.CompanyName)">
        <Directory Id="AppFolder" Name="!(loc.FolderName)" >
            <Component Id="DataDirectory" Guid="*">
                <CreateFolder>
                    <utils:PermissionEx User="[WIX_ACCOUNT_LOCALSYSTEM]" GenericAll="yes" 
                                        ChangePermission="yes" />
                </CreateFolder>
            </Component>
        </Directory>
    </Directory>
</Directory>

But it's not doing the trick. I am also trying this inside the service install, but no luck.

<utils:PermissionEx User="[WIX_ACCOUNT_LOCALSYSTEM]" GenericAll="yes" />

Any help is greatly appreciated.

Stein Åsmul
  • 39,960
  • 25
  • 91
  • 164

1 Answers1

0

Not really the core of my field, but in the interest of helping out, let us try: doesn't LocalSystem pretty much have "access all areas" on a normal computer? (with a few minor exceptions). There must be something else wrong? What do the logs say? What does the event viewer report?

Maybe see if some of these answers are illuminating?:

Stein Åsmul
  • 39,960
  • 25
  • 91
  • 164
  • Thank you! Although that was not the reason for my problem very helpful tips. What I was doing wrong was changing the name of my exe file, so the exe and config were different in name and was not loading the configuration. So, no DB. I very much appreciate the help. – Alfredo Chapela Aug 22 '18 at 15:30