Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / VB.NET / July 2007

Tip: Looking for answers? Try searching our database.

? on .bat with exclude

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
william ewald - 12 Jul 2007 14:52 GMT
Good day,
I am having an issue creating a backup.bat file that has an exclude
statement.  What I am trying to do is to backup the My Documents folder
off of C: while excluding the Music directory (to save space).  The
backed up files are copied to the mapped H: drive.  If anyone can see
where I have gone wrong please let me know.  Thank you!!!

Echo
SET ExclPath="C:\Documents and Settings\%username%\My
Documents\Exclude\exclude.txt"
XCOPY "C:\My Documents" /e /s /y H:/EXCLUDE: "C:\Documents and
Settings\%username%\My Documents\Exclude\exclude.txt"  

Errors =
Invalid number of parameters
rowe_newsgroups - 12 Jul 2007 15:30 GMT
> Good day,
> I am having an issue creating a backup.bat file that has an exclude
[quoted text clipped - 13 lines]
>
> *** Sent via Developersdexhttp://www.developersdex.com***

Well your first mistake is that you posted a vbscript question to the
Visual Basic .Net newsgroup.

Thanks,

Seth Rowe
william ewald - 12 Jul 2007 15:38 GMT
Thanks Seth.....and where should I post it?  

Bill Ewald
rowe_newsgroups - 12 Jul 2007 16:30 GMT
> Thanks Seth.....and where should I post it?
>
> Bill Ewald
>
> *** Sent via Developersdexhttp://www.developersdex.com***

I would say microsoft.public.scripting.vbscript

Thanks,

Seth Rowe
Michel Posseth  [MCP] - 12 Jul 2007 20:24 GMT
VBscript  ?????   huh   ...... :-)

i call this just DOS commands  , or command parameters , or Batching  but
VBscript .... no

It stays O.T.  for this group but however as i just one to beat myself on
the chest again for knowing the answer for this question
here it is :-)

This should work

xcopy "C:\Documents and Settings\Bla\My Documents" "H:\Backup\Michel" /I /E
/Y /C /V /R /Z /K /H /exclude:C:\Backupexclude\excludeList.txt

in the excludeList.txt

\My Documents\Music\
\My Documents\Movies\
\My Documents\Rubish\

Regards

Michel Posseth

> Good day,
> I am having an issue creating a backup.bat file that has an exclude
[quoted text clipped - 13 lines]
>
> *** Sent via Developersdex http://www.developersdex.com ***

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.