boxxer Posted August 13, 2005 Posted August 13, 2005 Hello, How can i set a Folder to Read Only? It's there only a function for files?! FileSetAttrib ( "file pattern", "+-RASHNOT" [, recurse] ) Thanks, John.
Developers Jos Posted August 13, 2005 Developers Posted August 13, 2005 Hello,How can i set a Folder to Read Only?It's there only a function for files?!FileSetAttrib ( "file pattern", "+-RASHNOT" [, recurse] )Thanks,John.<{POST_SNAPBACK}>Work also for Directories.... Just try it... SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
boxxer Posted August 13, 2005 Author Posted August 13, 2005 I've done this: FileSetAttrib ( "C:\Documents and Settings\MRX\Bureaublad\test", "-R",1 ) When i'm opening the Property window of this folder, the option of Read Only is checked. It should be unchecked..
BigDod Posted August 13, 2005 Posted August 13, 2005 I've done this:FileSetAttrib ( "C:\Documents and Settings\MRX\Bureaublad\test", "-R",1 )When i'm opening the Property window of this folder, the option of Read Only is checked.It should be unchecked..<{POST_SNAPBACK}>I have tried this as well and all folders under XP showup as Read 0nly marked by a green box. I also tried it on files and it sets/unsets the properties as required. In XP if you remove the read only then apply you will find that they change back automatically the next time you look at it. Time you enjoyed wasting is not wasted time ......T.S. Elliot Suspense is worse than disappointment................Robert Burns God help the man who won't help himself, because no-one else will...........My Grandmother
Developers Jos Posted August 13, 2005 Developers Posted August 13, 2005 I've done this:FileSetAttrib ( "C:\Documents and Settings\MRX\Bureaublad\test", "-R",1 )When i'm opening the Property window of this folder, the option of Read Only is checked.It should be unchecked..<{POST_SNAPBACK}>Works fine for me on WinXP Pro SP2... Just tested it on a folder on the desktop like you are doing:FileSetAttrib("C:\Documents and Settings\vanderzanjp\Desktop\test","+R",1) Sleep(5000) FileSetAttrib("C:\Documents and Settings\vanderzanjp\Desktop\test","-R",1) SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now