|
| | |||||||
| Windows XP Discuss the Microsoft Windows XP Operating System |
| | LinkBack | Thread Tools |
| |||
| dos batch script to make txt file with date in name hi how can i create a text file using dos batch file with date and time in name eg testThu 02/08/2007 2300.txt and also i want to read a text file which has list of IP address and execute same command one by one with all the ip address in the file the command is a snmp query getmany -v1 < ipaddr.txt public 1.3.6.1.4.1.x.x.x.x.x.x>>test.txt i tried few things able to put date and time in the file but not in name and cant read the input recursively from the ipaddress.txt file can some one Help Thanks in advance sandy |
| |||
| Re: dos batch script to make txt file with date in name "SANDY" <hugsandy******.com> wrote in message news:1170881069.868888.123010@a34g2000cwb.googlegr oups.com... > hi > how can i create a text file using dos batch file with date and time > in name > eg testThu 02/08/2007 2300.txt > > and also i want to read a text file which has list of IP address and > execute same command one by one with all the ip address in the file > the command is a snmp query > > getmany -v1 < ipaddr.txt public 1.3.6.1.4.1.x.x.x.x.x.x>>test.txt > > i tried few things able to put date and time in the file but not in > name > and cant read the input recursively from the ipaddress.txt file > > can some one Help > > Thanks in advance > sandy > Your first question: copy /y c:\test.txt "c:\%date:/=-% %time::=-%.txt" Your second question: @echo off for /F "tokens=*" %%* in ('type c:\IP.txt') do ( echo IP address=%%* ping %%* ) |
| Bookmarks |
| Thread Tools | |
| |
| | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Re: Help with a Batch file script (FTP) | Synapse Syndrome | Windows Vista | 0 | 10-26-2008 04:06 AM |
| Re: Help with a Batch file script (FTP) | Peter Foldes | Windows Vista | 0 | 10-26-2008 04:05 AM |
| Can I do this with a script or batch file? | Grey | Windows XP | 3 | 01-04-2007 05:05 AM |
| Simple Batch/Script file Question | Fidelis K | Windows XP | 0 | 01-04-2007 04:56 AM |
| How do you pass a vb script variable to a batch file? | Mike | Windows XP | 13 | 01-04-2007 03:03 AM |
| New To Technology Questions? | Do You Need Help with Your Computer or Device? | Do You Need Help with this site? |