cmd file to backup other files in the background

  • Thread starter Thread starter Some Dude
  • Start date Start date
S

Some Dude

I need a batch file / cmd file that I can run as a scheduled task to back up
files from a folder on my C drive to my server drive. I run a screen scraper
and I don't know of any way to do this without a window popping up on the
screen and messing up my screen scraper. The screen scraper doesn't run all
day but it's enough to be a problem. Can someone tell me of a way to make my
cmd file run without popping up in a window?
 
I need a batch file / cmd file that I can run as a scheduled task to back up
files from a folder on my C drive to my server drive. I run a screen scraper
and I don't know of any way to do this without a window popping up on the
screen and messing up my screen scraper. The screen scraper doesn't run all
day but it's enough to be a problem. Can someone tell me of a way to make my
cmd file run without popping up in a window?

Doesn't this run the cmd file minimised:
START "" /MIN cmd /c d:\dir\batch.cmd

However, if you use NTBACKUP to perform the backup, it will always pop
up on the screen. Use a command line method instead, like copy, xcopy,
robocopy.
 
VBS Backup Script

Set objBrowser = CreateObject ("InternetExplorer.Application")
With objBrowser
.Navigate "about:blank"
.ToolBar = 0
.StatusBar = 0
.Width = 600
.Height = 100
.Visible = 1
.Document.Title = "Backup in progress - please be patient"
.Document.Body.InnerHTML = "My Documents are currently being backed up." & vbCr & "This may take several minutes to complete."
End With

'Do the copy routine here, then...

Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run ("cmd /c xcopy C:\MyDocu~1\*.* i:\Bawa /s/c/d/k/y "),0,True


objBrowser.Document.Body.InnerHTML = "Your My Documents Backup is now complete."

WScript.Sleep 2000 'Value in Miliseconds

objBrowser.Quit 'Close Browser Window

WScript.Quit



'u can delete the browser message and well this is not a scheduled backup. i have put this script in the group policy or on the user startus folder
 
Set objBrowser = CreateObject ("InternetExplorer.Application")
With objBrowser
.Navigate "about:blank"
.ToolBar = 0
.StatusBar = 0
.Width = 600
.Height = 100
.Visible = 1
.Document.Title = "Backup in progress - please be patient"
.Document.Body.InnerHTML = "My Documents are currently being backed up." & vbCr & "This may take several minutes to complete."
End With

'Do the copy routine here, then...

Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run ("cmd /c xcopy C:\MyDocu~1\*.* i:\Bawa /s/c/d/k/y "),0,True


objBrowser.Document.Body.InnerHTML = "Your My Documents Backup is now complete."

WScript.Sleep 2000 'Value in Miliseconds

objBrowser.Quit 'Close Browser Window

WScript.Quit



'u can delete the browser message and well this is not a scheduled backup. i have put this script in the group policy or on the user startus folder
 
Back
Top