Sun Sep 05th 2010 
 
             
 
 
Showing 1 to 6 out of 6 | Page 1 of 1
Batch file to run a command on a remote machine
The easiest way to run a command on a remote machine without installing a service such as psexec is to create a Task on it and run it within the next minute. 

Date: 07/09/2008
Language: DOSAuthor: Tom

Map Network Drives at User logon
The script automatically maps network drives based on a users group membership in Active Directory. In this case I am using a static Fileserver (In this case we only have 1, so it's easy) and the following naming convention for the groups: FILE_%SERVERNAME%_%SHARENAME%_R (or W for "Write" access members) Driveletters and Sharenames can be modified in the arrShares string (actually it is not an array ;)) However, you can certainly modify the script to meet your requirements. 

Date: 11/14/2007
Language: VBAuthor: Tom

Active Directory User search
Active Directory searcher class. Returns an example set of AD attributes and takes the username to serach for. The return string is formatted to be used with a Console.WriteLine output. 

Date: 11/06/2006
Language: .NET C#Author: Tom

Replace a string in a text file
Replace a string in a text file using the command line.
Additionally you can add line numbers at the beginning of each line in a text file.
Usage: STREPLACE /F:[file] [options] | [[/S:string] [/R:string]]  

Date: 03/10/2006
Language: .NET C#Author: Tom

Check and restart a service
Uses WMI to determine if a service (in this case 'Microsoft Exchange Information Store') is running, and restarts the service if required.
Usage: cscript SRV_RestartService.vbs
Add a text file containing all machine names (line by line) called servers.txt into the same directory. 

Date: 11/30/2005
Language: VBAuthor: Tom

Delete files by date modified
Java script that deletes files or directories older than a specified date. Using the FileSystemObject gives us an excellent performance.
Usage: cscript SRV_Cleanup.js %directory% 

Date: 07/19/2005
Language: JScriptAuthor: Tom