cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
marketware
Level 6

Making a File Read/Write to anyone

I need to give Read/Write permission to a couple of files I am installing. I need anyone who logs onto the installed PC to be able to Read and Write and Delete those files.

My challenge is finding a "universal" group that I can use to set those permissions. I have users on XP, Vista and Windows 7. Is there a group that I can use that will be on any of those OSs so that anyone logging onto the PC will be able to have full control over those files?

BTW, sometimes an IT installs, and then later a user uses, so I need to make sure anyone who uses the PC can changes those files.

Thanks!

bob
Labels (1)
0 Kudos
(7) Replies
slalande50
Level 5

If you go to your component, click on the files item. Then right click on the files itself, you then click on the Permission button.

Right click in the Names field and click on the New.

Afterward remove the %USERDOMAIN and add USERS to the the user column.

Then click on the Full Control item to give full control to all users.

By the way, you can do the same for a folder by doing it in the "Files and Folders".

Hope it helps.
0 Kudos
BenMAC
Level 4

I have the same issue, but can't seem to find the permissions box.

When I open on a file's properties dialog, there is no permissions button available in the dialog.

Also, is it possible to set permissions for dynamic files? The properties context menu item is greyed out, so I assume not.

Can anyone offer any insight on this?

Thanks.
0 Kudos
MrTree
Level 6

which Projecttypes do you have?

In Installscript projects you can do something like this

   SetObjectPermissions(TARGETDIR, IS_PERMISSIONS_TYPE_FOLDER, "", "Everyone", DELETE|GENERIC_EXECUTE|GENERIC_READ|GENERIC_WRITE|FILE_DELETE_CHILD , 0);
0 Kudos
BenMAC
Level 4

Thanks for that reply.
Is there a way to query the install location from a component?
I'd rather not hard-code it somewhere. I also have some components that are stored in different places depending on the operating system, so I'd like to see if teh component is going to be installed at all.
0 Kudos
regexmaster
Level 5

slalande50 wrote:
If you go to your component, click on the files item. Then right click on the files itself, you then click on the Permission button.

Right click in the Names field and click on the New.

Afterward remove the %USERDOMAIN and add USERS to the the user column.

Then click on the Full Control item to give full control to all users.

By the way, you can do the same for a folder by doing it in the "Files and Folders".


Thank you for your answer. Would you happen to know if the "USERS" group exists for all OS Locales? (If not, I'll try it and post my results here.)

I once tried to set permissions for the "POWER USERS" (or similarly named) group, and it worked on English OS's, but failed on Finnish, Spanish, Chinese, etc. The only workaround I could find at the time was to use the "Everyone" group because but it always felt a little too loose for what I really wanted.

I've been hunting for exactly this kind of simple answer to this question and was lost in the sea of SID's and confounded by the documentation Microsoft's knowledge-base. (In fairness, the doc may have been very helpful and meaningful to someone who really knows about user account administration, but I am not he.)
0 Kudos
BenMAC
Level 4

One comment: the "permissions" button is not present in InstallScript applications.
0 Kudos
regexmaster
Level 5

regexmaster wrote:

I once tried to set permissions for the "POWER USERS" (or similarly named) group, and it worked on English OS's, but failed on Finnish, Spanish, Chinese, etc. The only workaround I could find at the time was to use the "Everyone" group because but it always felt a little too loose for what I really wanted.


Well, I found out my problem with "Users" had to do with my "General" setting to use "Traditional Windows Installer Handling" by for setting permissions. To my embarrassment there's even a note in the InstallShield's IDE to the effect that many well known SID's aren't supported on non-English locales. Sorry for all my noise 😕
0 Kudos