Search found 5 matches
- 17 Aug 2017 13:58
- Forum: DOS Batch Forum
- Topic: Batch Script - Using String as a delimter.
- Replies: 7
- Views: 4458
Re: Batch Script - Using String as a delimter.
Cool. Thank You..
- 16 Aug 2017 15:40
- Forum: DOS Batch Forum
- Topic: Batch Script - Using String as a delimter.
- Replies: 7
- Views: 4458
Re: Batch Script - Using String as a delimter.
Nice.. Thank You. It did work without adding the backslash.
Will there be any input file size limit when using for loop?
It would be great if you can share any previous posts are available on this topic.
Thanks !!
Will there be any input file size limit when using for loop?
It would be great if you can share any previous posts are available on this topic.
Thanks !!
- 16 Aug 2017 15:07
- Forum: DOS Batch Forum
- Topic: Batch Script - Using String as a delimter.
- Replies: 7
- Views: 4458
Re: Batch Script - Using String as a delimter.
Hi There, Let us say a input file with the following contents. File Name : Input.txt Input.txt file content: asd:asdfa:sdfwe:Firstonesecondonethirdonefourth Expected results: Out.txt: sdfwe Out2.txt: First Third somehow, below is not working. am i missing something ? @echo off setlocal for /f "...
- 15 Aug 2017 15:56
- Forum: DOS Batch Forum
- Topic: Batch Script - Using String as a delimter.
- Replies: 7
- Views: 4458
Re: Batch Script - Using String as a delimter.
Very cool. That works. Thank you ! You only can work around it e.g. using string manipulation. Choose a character that most likely won't occur in your strings. Replace "one" with this character and use it as delimiter. set "str=CheckoneThat" for /f "tokens=1,2 delims=~"...
- 15 Aug 2017 14:50
- Forum: DOS Batch Forum
- Topic: Batch Script - Using String as a delimter.
- Replies: 7
- Views: 4458
Batch Script - Using String as a delimter.
Hi,
Can we use string as a delimiter ? ( Please see below. "one" is string delimiter )
for /F "tokens=1,2 delims=~" %%a in ("CheckoneThat") do
(
echo %%a>>Out.txt
echo %%b>>Out.txt
)
Expected Results:
Check
That
-Thanks
Can we use string as a delimiter ? ( Please see below. "one" is string delimiter )
for /F "tokens=1,2 delims=~" %%a in ("CheckoneThat") do
(
echo %%a>>Out.txt
echo %%b>>Out.txt
)
Expected Results:
Check
That
-Thanks