Replace a character to another one in a text file using Windows batch file -
i'm trying write batch file replace every character . / in test.txt. however, wrong , outfile.txt generated empty.
@echo off setlocal enabledelayedexpansion set "sourcedir=c:\users\acaproni\desktop" set "destdir=c:\users\acaproni\desktop" set "filename=%sourcedir%\test.txt" set "outfile=%destdir%\outfile.txt" ( /f "usebackqdelims=" %%a in ("%filename%") ( set "line=%%a" set "line=!line:.=/!" echo !line! ) )>"%outfile%" goto :eof anyone can me?
Comments
Post a Comment