Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Set Permissions on folder. 1

Status
Not open for further replies.

wibbe

IS-IT--Management
Oct 30, 2002
68
0
0
SE
Hi,

I have made a msi for one old application using Group Policy to install it on the clients.
The installation works fine but..
..the application requires that the user have full access to a folder (c:\program files\application\temp).
How can I set NTFS permissions on a folder with msi?

I have read all previus articles and found this comment from "prestorush (IS/IT--Manageme)" in May 22, 2003

"Can you create a wise installation system 9 script to share a folder? I have the script source to set perminssions on a folder but I really need to automate the folder sharing process during my install. Thanks! "

So I guess there is a solution to my problem. But can anyone post this script?

Best Regards
Wibbe
 
On the setup editor tab, choose components.
Either pick an existing component doing something to that folder or create a new component.
Right click the component, Create folder.
Write the name of the folder in question. You will probably be able to find it in the drop down list.
When the folder is created, right click the folder in the right pane and select details.
On the permission tab add your domain and Domain admins, authenticated users etc.
Choose the permission the various users need.
Give the permissions on the subfolder, that is do not give these permissions on say the program files folder or the windows folder. Once you uninstall the msi, you could mess up your machine real well this way.

You can give permissions to a specific file or a reg key this way.

Martin
 
Thanks MMV

It worked out perfect.

/ Wibbe
 
One caveat. If Windows Installer does not *create* the file/folder/regkey you want to set permissions on, it will not change the permissions. You must pre-delete the entry or use an external tool (setacls, cacls, etc).

Regards,

Rob
robschultz@yahoo.com
-Focus on the solution to the problem, not the obstacles in the way.-
 
Not true. You can use it to give you permissions on the Windows folder if you like. Just pay attention to the fact that you can ruin the OS, if you alter too much.
 
Sorry, I should have been more specific. It will set the permissions on the top-level key/folder but won't trickle down to sub-folders/sub-keys.

Regards,

Rob
robschultz@yahoo.com
-Focus on the solution to the problem, not the obstacles in the way.-
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top