Localzuk made something similar without the sharing bit from the code of SetACL (opensource) and was good enough to post if for everyone here: Setting folder owners programatically
I've got an old application (VB6) that creates user shares and sets NTFS permissions that has worked since Windows 2000.
Now Server 2008/64bit has come along, and it won't work at all so it looks like a re-write. I'm using Visual Basic Express 2008 and so far can't see to find a simple way to do the following:
- Create a folder on a local drive
- Share the above folder (and set the share permissions)
- Set the permissions for a folder within that share and set them to replicate downwards
Has anyone got a code snippet or example they can show me? I'm going around circles here trying to find a way around this!
Cheers for that - its a shame I can't register the ADsSecurity.dll on the Server 2008 box as that would save me a lot of time. This lets me set NTFS permissions quite easily
Not sure why I can't register it - it works ok on Server 2003 and various other Windows variants.
Sorry I wrote that wrong! I could register it,but it bombs out the program as soon as you try to create an object.
I've had to go backwards and simply use Shell commands to use cacls , which works. Seems a shame to go back to DOS commands but ADsSecurity is from 2001 and theres no update!
It's probably too late but I have some free utilities which handle creating shares, setting permissions, and propagating them accordingly. I used to have them on my website at ANB Software Homepage but removed them when I merged them all together to make paid for applications. If you still need these then email me at email@example.com and I will email them over to you.
There are currently 1 users browsing this thread. (0 members and 1 guests)