PDA

View Full Version : Permissions setting to edit within directory



zac_rscom
06-26-2013, 02:45 PM
Is there a setting in InstallShield to allow our software to be able to create and edit files and folders within the directories installed when our software is installed? Without having to have administrator rights? So if our software wanted to create a new file within its own directories, it wouldn't have to ask for an admin password?

zac_rscom
06-26-2013, 05:13 PM
We tried following these instructions I found online:

Go to the Application Data group, Files view in the InstallShield IDE. In the Destination computer's folders pane, find the directory you want to set the permissions for, right-click it, select Properties, then click the Permissions button. A dialog box will open where you can set a Domain, a User, and the permissions, including Full Control, Modify, Read & Execute, List Folder Contents, Read, Write, and Special Permissions

But we get an error during the install that says:

Internal Error 27555. C\program Files\Rescuecom\rescuecom…\. The requested lookup key was not found in any active activation context.

.14007
Any ideas?

phill_mn
06-27-2013, 09:23 AM
I imply from your comments that you are using a MSI project and that you are trying to give a user write access to a folder under the "Program Files" tree. If correct, I think the error you are seeing is because Microsoft does not want you to give users access under the program files tree. To allow users write access to that location is considered a major security breach. A file that a non-privledged user should edit should not be located in this area of the file system. Consider putting the files in the user's appdata folder.

If this is not your issue, I apologize. If using MSI the help document that you referenced describes several MSI tables. From within InstallScript code call SetObjectPermissions to configure the permissions of a file or folder. But here again the OS will prevent you from changing the permissions for some of the system-defined folder locations. The call may fail or it may just not do anything when you target a system-defined folder tree (including sub-folders that you create under certian areas).
http://helpnet.flexerasoftware.com/installshield18helplib/mergedProjects/installshield18langref/SetObjectPermissions.htm