PDA

View Full Version : Folder Creation



sm22
01-02-2002, 12:52 AM
I am fairly new to scripting so any help is appreciated.

Is there any way to create a script that will create a folder and assign appropriate permissions. I have a Windows 2000 network with AD installed my users have a bunch of different folders that directly relates to a Contact Managment Software ie; GoldMine. At this point I am manually creating and setting up the folders and permission. I would like to in the future automate this proccess for our HR department.

Thanks All!

darkness
01-07-2002, 01:54 PM
Yup I am working on a similar system.

Note here's a snipit for creating the folder:

Set fso = CreateObject("Scripting.FileSystemObject")
fso.CreateFolder ("C:\Bogus")

To assign permissions is something different. You can use ACL's but it is really Dry and will triple your script size, and just make life a Pain. My suggestion, and the one MS suggests is a command in the Resource Kit called Xcacls.exe. This is a command line command and you would just pass a Wscript command to the shell to process the folder permissions change.

Hope this Helps


Michael McLaughlin/images/forums/icons/smile.gif
Systems Manager
Minnesota State University Mankato