Hey Friends,
I have a text file name as abc.txt and the data reside as below:
Computer hope/abc/file_name.xml
Computer hope/abc/file_name2.xml
Hope Computer/def/file_name3.xml
....
So now i want the trimmed data from the abc.txt file to new file named as def.txt
file_name.xml
file_name2.xml
file_name3.xml
Can you please help me in this, can we create batch file for this ?
I have tried searching online but get it below code but not what i want.
@ECHO off
cls
setlocal enableextensions enabledelayedexpansion
set num=15 ::trimmed letters
set /a num=%num%+1
for /f "tokens=* delims= " %%f in (abc.txt) do (
set a=%%f
echo !a:~0,%num%!
echo !a:~0,%num%! >>def.txt
)
pause
Thanks,
hope to hear back from you soon.