Issue
I set a variable in cmd with the set
command, and tried to echo
it.
Here is an example:
C:\Users\Logan>set var = text
C:\Users\Logan>set var
var = text
C:\Users\Logan>echo %var%
%var%
C:\Users\Logan>
Is there a way to force the cmd to echo
the variable and not the raw text?
Solution
You need to remove whitespace before and after =
:
set "var=text"
echo %var%
text
Answered By - CrYoSoRe Answer Checked By - Candace Johnson (PHPFixing Volunteer)
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.