Jump to content

Looking For...ways To Change File\folder Permissions


Recommended Posts

I just had to build a file permission script via the GUI cuz I couldn't find a way to do this programmatically...damn what a pain.

Am I missing something. It seems like there should be a function that would give one the ability to set/modify permission settings on files and folders (as long as the current user or RUNAS had permissions to do so).

Any ideas?

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

AutoIt Console written in C#. Write au3 code right at the console :D_FileWriteToLineWrite to a specific line in a file.My UDF Libraries: MySQL UDF Library version 1.6 MySQL Database UDF's for AutoItI have stopped updating the MySQL thread above, all future updates will be on my SVN. The svn location is:kan2.sytes.net/publicsvn/mysqlnote: This will still be available, but due to my new job, and school hours, am no longer developing this udf.My business: www.hirethebrain.com Hire The Brain HireTheBrain.com Computer Consulting, Design, Assembly and RepairOh no! I've commited Scriptocide!
Link to comment
Share on other sites

That is only file *attributes*....nothing in there about dealing with user/group account permissions to the files/folders which is what I am looking for.

Maybe I wasn't clear.

Edited by sshrum

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

I just had to build a file permission script via the GUI cuz I couldn't find a way to do this programmatically...damn what a pain.

Am I missing something. It seems like there should be a function that would give one the ability to set/modify permission settings on files and folders (as long as the current user or RUNAS had permissions to do so).

Any ideas?

i think i remember a program called setacl or something like that, which does precisely what you need. search the forums for 'permissions file registry' and you should see it mentioned...
Link to comment
Share on other sites

You can use the 3rd party tool setacls as cameronsdad suggested, or you can try cacls which comes with Windows. It's not as nice, but if you use it then that one less external file you have to distribute with your script.

Link to comment
Share on other sites

Good point and really what I was going for with my last statement.

I think I'll play around with the cacls a bit.

Most of what I need done is file permissions changes (and a few reg permissions now and then)

Thanks for the info.

Sean Shrum :: http://www.shrum.net

All my published AU3-based apps and utilities

'Make it idiot-proof, and someone will make a better idiot'

 

Link to comment
Share on other sites

I scripted this sometime back. I used CACLS. The only downside is that the CACLS command doesn't propergate through directories. This means that you have to set up a loop to query the file attributes. If its a folder, then go deeper into the file structure.

Link to comment
Share on other sites

I scripted this sometime back. I used CACLS. The only downside is that the CACLS command doesn't propergate through directories. This means that you have to set up a loop to query the file attributes. If its a folder, then go deeper into the file structure.

I never had a problem with /T switch.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...