Search found 6 matches
- 05 Feb 2020 14:30
- Forum: DOS Batch Forum
- Topic: Batch script to exctract everything between 2 regex
- Replies: 10
- Views: 12362
Re: Batch script to exctract everything between 2 regex
Thanks, I get a lot of these documents every month and they are not always so predictable, so I would appreciate if you could help me out with a few more codes in order to do any other possible scenario 1. String 1 2. String 2 3. String 3 4. String 4 5. String 5 Keep everything ABOVE String 2 Keep e...
- 05 Feb 2020 13:14
- Forum: DOS Batch Forum
- Topic: Batch script to exctract everything between 2 regex
- Replies: 10
- Views: 12362
Re: Batch script to exctract everything between 2 regex
Yes now its working fine, Thank You. It seems like it needs the whole line value and not just a partial value.
Now, is there any way to do the complete opposite? Keep only the content OUTSIDE that range.
Now, is there any way to do the complete opposite? Keep only the content OUTSIDE that range.
- 05 Feb 2020 07:17
- Forum: DOS Batch Forum
- Topic: Batch script to exctract everything between 2 regex
- Replies: 10
- Views: 12362
Re: Batch script to exctract everything between 2 regex
Also, does the '' around "line2" are necesary?
- 05 Feb 2020 07:16
- Forum: DOS Batch Forum
- Topic: Batch script to exctract everything between 2 regex
- Replies: 10
- Views: 12362
Re: Batch script to exctract everything between 2 regex
If I add that code to a .bat file i get
JScript runtime error opening input file: File not found
If i try to use it on a CMD window opened on the directory i get
%%F was unexpected at this time.
All the files in that directory have different names
JScript runtime error opening input file: File not found
If i try to use it on a CMD window opened on the directory i get
%%F was unexpected at this time.
All the files in that directory have different names
- 04 Feb 2020 12:21
- Forum: DOS Batch Forum
- Topic: Batch script to exctract everything between 2 regex
- Replies: 10
- Views: 12362
Re: Batch script to exctract everything between 2 regex
Ok sorry for not giving info. Here is an example I have a lot of files in a folder, with many names, all are *.txt Original_file.txt Line 1 Line 2 Line 3 Line 4 Line 5 I want a new file (or the file itself can be modified) with this result Output_file.txt Line 3 Line 4 The point is, getting everythi...
- 04 Feb 2020 09:54
- Forum: DOS Batch Forum
- Topic: Batch script to exctract everything between 2 regex
- Replies: 10
- Views: 12362
Batch script to exctract everything between 2 regex
Hello everyone. I am new to programming I have about 400 *.txt files in a folder, they all contain data between 2 specific text and I need that data either in a new file (one file per *.txt) I have read about jrepl.bat but i really have no idea how to do it i have try everything and nothing works. C...