@echo off
FOR /F "delims=" %%G IN (file_names.txt) DO (
set "FILE=%%G"
setlocal enabledelayedexpansion
set "file1=hello!FILE!"
echo !FILE!
echo !file1!>>output.txt
endlocal
)
Search found 21 matches
- 08 Jun 2012 05:22
- Forum: DOS Batch Forum
- Topic: Prepending string to each line
- Replies: 3
- Views: 5551
- 17 May 2012 04:26
- Forum: DOS Batch Forum
- Topic: Date And Time not getting Updated....!
- Replies: 5
- Views: 4051
Re: Date And Time not getting Updated....!
it worked.
thnks foxidrive...!
thnks foxidrive...!
- 17 May 2012 03:22
- Forum: DOS Batch Forum
- Topic: Date And Time not getting Updated....!
- Replies: 5
- Views: 4051
Re: Date And Time not getting Updated....!
how?
will it get updated?
because i am using that for 20 times
will it get updated?
because i am using that for 20 times
- 17 May 2012 01:11
- Forum: DOS Batch Forum
- Topic: Date And Time not getting Updated....!
- Replies: 5
- Views: 4051
Date And Time not getting Updated....!
hi everyone, i am calling many batch file from one batch file. the one batch file from which i am calling other batch files contains this echo %DATE:~10,4%-%DATE:~4,2%-%DATE:~7,2% %TIME:~0,2%:%TIME:~3,2%:%TIME:~6,2% Starting the 1st process...! 2nd process...! nth process...! what happens here is wi...
- 14 May 2012 07:51
- Forum: DOS Batch Forum
- Topic: can we login into gmail account using batch?
- Replies: 9
- Views: 8801
Re: can we login into gmail account using batch?
my requirement is after every reboot the batch program file should start.
and it should open the my gmail inbox.
before admin login on my machine.
i know how to start it after reboot but i dont know if i can open gmail inbox using batch file.
and it should open the my gmail inbox.
before admin login on my machine.
i know how to start it after reboot but i dont know if i can open gmail inbox using batch file.
- 14 May 2012 06:12
- Forum: DOS Batch Forum
- Topic: can we login into gmail account using batch?
- Replies: 9
- Views: 8801
Re: can we login into gmail account using batch?
no no i don't want to send and receive mail.
i am just asking is it possible or not.
and if it is possible then how?
and if it is not then why not?
i am just asking is it possible or not.
and if it is possible then how?
and if it is not then why not?
- 13 May 2012 23:06
- Forum: DOS Batch Forum
- Topic: can we login into gmail account using batch?
- Replies: 9
- Views: 8801
can we login into gmail account using batch?
hi everyone,
i would like to know can we log in into our gmail account using batch file.?
username and password should be set in batch file only.
thank you!
i would like to know can we log in into our gmail account using batch file.?
username and password should be set in batch file only.
thank you!
- 08 May 2012 07:28
- Forum: DOS Batch Forum
- Topic: Copy folders with filename
- Replies: 10
- Views: 9649
Re: Copy folders with filename
hi Squashman,
yes you are right....!
yes you are right....!
- 08 May 2012 06:45
- Forum: DOS Batch Forum
- Topic: Copy folders with filename
- Replies: 10
- Views: 9649
Re: Copy folders with filename
@echo off FOR %%G IN (*_imp.png) DO ( echo file found...! echo %%~nG > file.txt FOR /F "delims=_" %%M IN (file.txt) DO ( echo %%M mkdir %%M cd %%M move /y ..\*.png cd.. ) ) just put this bat in that folder in which *_imp.png is there. and after that u will get all .png in that perticular f...
- 08 May 2012 06:25
- Forum: DOS Batch Forum
- Topic: Copy folders with filename
- Replies: 10
- Views: 9649
Re: Copy folders with filename
replace this
move /y blue\*.png %%M\
with
move /y blue\* %%M\
done....!
and just replace blue with whatever folder u want.
cntrl+f then find blue replace with green.
done.....!
move /y blue\*.png %%M\
with
move /y blue\* %%M\
done....!
and just replace blue with whatever folder u want.
cntrl+f then find blue replace with green.
done.....!
- 08 May 2012 01:08
- Forum: DOS Batch Forum
- Topic: Copy folders with filename
- Replies: 10
- Views: 9649
Re: Copy folders with filename
@echo off cd blue FOR %%G IN (*_imp.png) DO ( echo file found...! echo %%~nG > file.txt FOR /F "delims=_" %%M IN (file.txt) DO ( echo %%M cd.. mkdir %%M move /y blue\*.png %%M\ echo y | del blue ) ) rmdir blue and make sure you run this program from outside blue folder. suppose you have bl...
- 07 May 2012 23:42
- Forum: DOS Batch Forum
- Topic: can Variables value altered mltiple times in 1 .bat file?
- Replies: 6
- Views: 5069
Re: can Variables value altered mltiple times in 1 .bat file
hi Squashman
thnks for suggestion but i need to use that value at almost 30 places.
so i cant use %%G thirty times because it makes my code so unreadable and also makes it difficult to understand.
that's why i need variable.
thnks for suggestion but i need to use that value at almost 30 places.
so i cant use %%G thirty times because it makes my code so unreadable and also makes it difficult to understand.
that's why i need variable.
- 07 May 2012 05:23
- Forum: DOS Batch Forum
- Topic: can Variables value altered mltiple times in 1 .bat file?
- Replies: 6
- Views: 5069
Re: can Variables value altered mltiple times in 1 .bat file
thnks !k
this worked for me...!
cheers....!
this worked for me...!
cheers....!
- 07 May 2012 02:05
- Forum: DOS Batch Forum
- Topic: can Variables value altered mltiple times in 1 .bat file?
- Replies: 6
- Views: 5069
can Variables value altered mltiple times in 1 .bat file?
hi i m having one .txt file that contains the different name of the files. so using for loop i m displaying the different file names contained in that file. FOR /F "tokens=* delims= " %%G IN (file_names.txt) DO ( set k= %%G echo %k% ) the .txt contains 7 file names. but every time only one...
- 27 Apr 2012 07:55
- Forum: DOS Batch Forum
- Topic: character conversion error......!
- Replies: 13
- Views: 11113
Re: character conversion error......!
hi aGerman,
your solution worked great.
can u tell me what did you do by asking me those numbers?
what about first program? what u did there?
what those numbers indicates?
and what about second program?
what you are doing over there?
your solution worked great.
can u tell me what did you do by asking me those numbers?
what about first program? what u did there?
what those numbers indicates?
and what about second program?
what you are doing over there?