Search found 6 matches
- 27 Aug 2010 14:13
- Forum: DOS Batch Forum
- Topic: Using a Varible with Set command
- Replies: 1
- Views: 3477
Using a Varible with Set command
Hello All Is it possible to use a varible with the set command? Im trying to create a directory to backup files into. So Im using the "set BACKUP_DIR=\ESM_Backup_5_x\Latest" however I would like to have the script name the folder with the current date and time. The problem is throughout th...
- 26 Aug 2010 09:31
- Forum: DOS Batch Forum
- Topic: Creating fold using trime date stamp
- Replies: 10
- Views: 11147
Re: Creating fold using trime date stamp
Thanks that worked great!
- 25 Aug 2010 15:56
- Forum: DOS Batch Forum
- Topic: Creating fold using trime date stamp
- Replies: 10
- Views: 11147
Re: Creating fold using trime date stamp
Ok I have the bat file working great. I would like to add a log file that keeps track of failures. In the event of a failure the script does the following; :exitError echo. echo Backup Failed! echo. pause exit /B 1 could I add something like "echo failed >> c:\log.txt" to create a log file...
- 25 Aug 2010 10:55
- Forum: DOS Batch Forum
- Topic: Creating fold using trime date stamp
- Replies: 10
- Views: 11147
Re: Creating fold using trime date stamp
Hehe, I get the feeling a lot of people come here expecting someone to write or fix their script rather than lead them in the right direction. Netcom, I don't fully understand your problem or script, but if you're trying to put the current date into the name of a new directory, the script would go ...
- 25 Aug 2010 09:14
- Forum: DOS Batch Forum
- Topic: Creating fold using trime date stamp
- Replies: 10
- Views: 11147
Re: Creating fold using trime date stamp
Thanks for your help, But Im not sure understand how to use that in my script. Im pretty new to this stuff. So if I understand correctly I would use set filename=%date:~0,14% ipconfig >> "c:\%filename%.txt" and that would create a new folder with the currently date/time? How would I add th...
- 24 Aug 2010 16:02
- Forum: DOS Batch Forum
- Topic: Creating fold using trime date stamp
- Replies: 10
- Views: 11147
Creating fold using trime date stamp
Hello All, Im trying to modify the below script to create the folder woth a time/date stamp each time the batch file is ran. Currently the batch file stops in error if a folder exist. Whats the easiest was to accomplish this? @echo off : : BackupESM.bat : : This batch file will save a backup of the ...