Reputation: 1558
I am making a call to: config.Save(ConfigurationSaveMode.Modified); and this call works fine in Windows XP.
When I run it in Vista I get:
Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Configuration.ConfigurationErrorsException: An error occurred loading a configuration file: Access to the path 'C:\Windows\system32\2lqfj0cv.tmp' is denied. (C:\Windows\system32\MsiExec.config) ---> System.UnauthorizedAccessException: Access to the path 'C:\Windows\system32\2lqfj0cv.tmp' is denied.
Now I guss the pertinent fact here is that I am running the call above from a Windows Installer MSI (call to a managed DLL). I guess I need to do something to up the user permissions? I really don't know a lot about Vista permissions?
Upvotes: 1
Views: 373
Reputation: 22443
Try using run as admin. Also do you mean to be editing the MSIEXEC.config?
http://msdn.microsoft.com/en-us/library/bb756929.aspx
Upvotes: 1