I want to replace <Context useHttpOnly="false"> with <Context>
for /f "tokens=* delims=" %%A in ( %INTEXTFILE%) do (
SET string=%%A
setlocal enabledelayedexpansion
SET modified=!string:^<Context useHttpOnly^="false"^>=^<Context!
echo !modified! >> %OUTTEXTFILE%
endlocal
)
Output: nothing change.
Problem found because of equal sign and double quotes.