I am having an issue with setting a variable from a text file in a batch script.
There is only one line in the text file and it is testabc.
The script is
set /p p_password=<c:\temp\passport.txt
echo %p_password%
The echo statement should have testabc, but it is actually having the below ■t.
I even tried it with a for loop
for /f "delims=" %%a in (c:\temp\passport.txt) do set p_password=%%a
echo %p_password%
I still get the same output; ■t
Any help is much appreciated.