Scripts Thread, Wanted: VBScript to delete folders from C: in Coding and Web Development; Im in need of a script that will delete folders from C:
Now i can do it if the user ...
6th February 2008, 12:53 PM #1
Wanted: VBScript to delete folders from C:
Im in need of a script that will delete folders from C:
Now i can do it if the user has got permissions to access the C: but i need a way to run the script as an administrator so the folder will be deleted as users here cannot alter C:
It is to delete local profiles of users when they log off. So i know that somewhere in the script needs to be c:\documents and settings\%username%
Can someone help?
Last edited by timbo343; 6th February 2008 at 01:11 PM.
6th February 2008, 01:12 PM #2
Can you not run it as a startup script?
That would be the easiest way I think.
6th February 2008, 01:13 PM #3
Can this not be done with Active Directory? Failing that, a startup/shutdown script sounds like it will do the biz.
6th February 2008, 01:15 PM #4
Originally Posted by jinnantonnix
6th February 2008, 01:20 PM #5
6th February 2008, 01:22 PM #6
With a startup/shutdown script, dont all the computers have to be in that particular group?
6th February 2008, 01:28 PM #7
Are they not in the same OU?
Originally Posted by timbo343
You could create a Policy linked to that OU and bob's your uncle!
7th February 2008, 12:50 PM #8
I'd certainly make sure that all "standard" workstations are under a top level OU - eg we have one called "allPCs"; that has sub-ous for each site then further OUs for each room.
Originally Posted by GlennT
It means a policy can be attached to allpcs which applies to ... All PCs :-)
Alternatively, link it at the domain level and make it check for servers (say) and exclude them (easy if your servers have a standard naming convention otherwise you can use WMI to find the software type and use that to exclude servers)
Last Post: 23rd September 2011, 04:21 PM
Last Post: 14th January 2008, 12:39 AM
By timbo343 in forum Scripts
Last Post: 19th September 2007, 11:46 PM
By StewartKnight in forum Coding
Last Post: 1st May 2007, 12:04 PM
By mac_shinobi in forum Scripts
Last Post: 14th September 2005, 09:21 AM
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)