Search found 20 matches
- 19 Sep 2018 02:17
- Forum: DOS Batch Forum
- Topic: Show date in order I want it to
- Replies: 4
- Views: 5637
Re: Show date in order I want it to
Thank you, got it to work, thanks for the help and info
- 12 Sep 2018 01:25
- Forum: DOS Batch Forum
- Topic: Show date in order I want it to
- Replies: 4
- Views: 5637
Show date in order I want it to
Hi I have this code, that I got from the internet, but the date is in the wrong order, how can I change it to show DD/MMMM/YYYY. @echo off set /p host=host Address: set logfile=Log_%host%.log echo Target Host = %host% for /f "tokens=*" %%A in ('ping %host% -n 1 ') do (echo %%A && GOTO Ping) :Ping fo...
- 07 Apr 2017 03:35
- Forum: DOS Batch Forum
- Topic: use bat file to open application then file
- Replies: 3
- Views: 4219
Re: use bat file to open application then file
penpen wrote:It heavily depends on the application you are using - but to be honest:
It sounds more like a job for AutoIt to me.
(Although you probably may also use hybrid jscript/bat or C#/bat scripts .)
Did look at Autoit, but at the moment does not understand it.
Will try to look hybird jscript
penpen
- 07 Apr 2017 00:25
- Forum: DOS Batch Forum
- Topic: use bat file to open application then file
- Replies: 3
- Views: 4219
use bat file to open application then file
I want to know if this is possible.
I am opening a application ,then I open a file form there, then I open the application again and open a new file, so there are now two files open with it.
can this be done with a bat file at all.
I am opening a application ,then I open a file form there, then I open the application again and open a new file, so there are now two files open with it.
can this be done with a bat file at all.
- 03 Oct 2013 09:49
- Forum: DOS Batch Forum
- Topic: How to copy files, but not all of them
- Replies: 11
- Views: 8509
Re: How to copy files, but not all of them
Foxidrive
Thank You, it is working now
Thank You, it is working now
- 03 Oct 2013 07:20
- Forum: DOS Batch Forum
- Topic: How to copy files, but not all of them
- Replies: 11
- Views: 8509
Re: How to copy files, but not all of them
Thank you will let you know how it is working, on the train on my way home
- 03 Oct 2013 06:55
- Forum: DOS Batch Forum
- Topic: How to copy files, but not all of them
- Replies: 11
- Views: 8509
Re: How to copy files, but not all of them
Hi
if I have a date for today, it must copy it to folder, if the date is yesterday and older it must not be copied.
So inly dates for today's date must be copied.
Sorry if I am confusing you.
if I have a date for today, it must copy it to folder, if the date is yesterday and older it must not be copied.
So inly dates for today's date must be copied.
Sorry if I am confusing you.
- 03 Oct 2013 06:32
- Forum: DOS Batch Forum
- Topic: How to copy files, but not all of them
- Replies: 11
- Views: 8509
Re: How to copy files, but not all of them
Ok I see now where the problem is, I did copy the new code and run it. The Windows GP Clients.txt and Windows GP Backup.txt is the only two files that have changed today, they must be copied to folder, but did not. The Windows GP Restore.txt and Windows GP Tapes.txt did not change today, and should ...
- 03 Oct 2013 01:22
- Forum: DOS Batch Forum
- Topic: How to copy files, but not all of them
- Replies: 11
- Views: 8509
Re: How to copy files, but not all of them
@echo off for /f "tokens=2 delims==" %%a in ('wmic OS Get localdatetime /value') do set "dt=%%a" set "YY=%dt:~2,2%" & set "YYYY=%dt:~0,4%" & set "MM=%dt:~4,2%" & set "DD=%dt:~6,2%" call :check_copy "D:\Users\hbezuidenhout\...
- 03 Oct 2013 00:44
- Forum: DOS Batch Forum
- Topic: How to copy files, but not all of them
- Replies: 11
- Views: 8509
Re: How to copy files, but not all of them
You incorrectly changed the MD to CD. There is no need to CD to the folder because the full path is specified in the copy command. Ok I did change it from MD to CD, because the folder did already exist, but I will then take all the lines with cd out. I did think it should be in. Another issue above...
- 03 Oct 2013 00:22
- Forum: DOS Batch Forum
- Topic: How to copy files, but not all of them
- Replies: 11
- Views: 8509
How to copy files, but not all of them
Thanks to Foxidrive for helping me with this code. I just want to know if this is possible with a bath file. I have 12 txt files that I want to copy (This is working) renaming them in new folder (this is working) But not all of them change every day, so how can I only let the files that I change tod...
- 02 Oct 2013 06:33
- Forum: DOS Batch Forum
- Topic: Batch file to copy and rename file with today's date
- Replies: 5
- Views: 28224
Re: Batch file to copy and rename file with today's date
Thank you foxidrive
- 02 Oct 2013 06:08
- Forum: DOS Batch Forum
- Topic: Batch file to copy and rename file with today's date
- Replies: 5
- Views: 28224
Re: Batch file to copy and rename file with today's date
When I run this code
it does show me that I am on the correct folder
so I think the problem is in this code
Code: Select all
echo Current Directory = %CD%
it does show me that I am on the correct folder
so I think the problem is in this code
Code: Select all
ren "D:\Users\hbezuidenhout\Documents\WindowsGP\Restore\WindowsGPRestore.txt" "WindowsGPRestore%DATE%.txt"
- 02 Oct 2013 05:14
- Forum: DOS Batch Forum
- Topic: Batch file to copy and rename file with today's date
- Replies: 5
- Views: 28224
Re: Batch file to copy and rename file with today's date
Thank you, but I am getting error The system cannot find the path specified I think is on the first line cd D:\Users\hbezuidenhout\Documents\Windows(GP)\Restore ren "D:\Users\hbezuidenhout\Documents\Windows(GP)\Restore\Windows(GP)Restore.txt" "Windows(GP)Restore %DATE%.txt" Here ...
- 02 Oct 2013 04:23
- Forum: DOS Batch Forum
- Topic: Batch file to copy and rename file with today's date
- Replies: 5
- Views: 28224
Batch file to copy and rename file with today's date
I have about 9 txt files that I want to copy to 9 different folder (This is working) I then want to rename each file with today's date, but it must not override the files of the previous day (cannot get it to work) cd\Users\hbezuidenhout\Documents xcopy "d:\Users\hbezuidenhout\Documents\Windows...