Folks,
hope all are good.:)
Can a batch expert help me with this batch file.
I simply wanted to extract some text from text files
Begin sampletext End >> file1.txt
Begin anotherlineoftext End >> file2.txt
Out put these text strings to a new text file
I wanted to run it on my folder of text files.
I found this – but still confused
@ECHO OFF SETLOCAL SET "sourcedir=c:sourcedir" ' current folder SET "destdir=c:destdir" for /f "tokens=1 delims=[]" %%a in ('find /n "'Parent|Child"^<"%sourcedir%Cost_Center.txt" ') do set /a start=%%a for /f "tokens=1 delims=[]" %%a in ('find /n "!PropertyArray= Begin Center"^<"%sourcedir% folder files " ') do set /a end=%%a ( for /f "tokens=1* delims=[]" %%a in ('find /n /v ""^"%destdir%newfile.txt" GOTO :EOF
I don’t know how to fix this, it seems really complicated now.
I have very basic experience of cmd and batch filing – so any advice really appreciated
many thanks for your advice
pb