Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBscript on MS Server 2003

Status
Not open for further replies.

JV28132

Programmer
Apr 19, 2010
11
US
Can a vbscript movefiles from one place to another when it is executed on SQL Server 2003?
 
Sure why not? You might want to script the use of ROBOCOPY to have more advanced copy options. Something like this:

Code:
Set WSHShell = CreateObject("Wscript.Shell")

SourceDir = "C:\Test1"
DestDir = "C:\Test2"

WSHShell.Run "CMD.EXE /C ROBOBCOPY " & SourceDir & " " & DestDir & " " & "/S /E /XO /R:0 /W:0"

I hope that helps.

Regards,

Mark

Check out my scripting solutions at
Work SMARTER not HARDER. The Spider's Parlor's Admin Script Pack is a collection of Administrative scripts designed to make IT Administration easier! Save time, get more work done, get the Admin Script Pack.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top