Extract all but the first character in batch? -


to extract first character use:

%var:~0,1% 

to extract last character use:

%var:~0,-1% 

so how extract except first character?

i tried looking in "set /?" under cmd prompt didn't help.

to extract specific character end of string, specify starting index:

%var:~1% 

this covered in set /? it's buried inside paragraph , not easy find:


may specify substrings expansion.

%path:~10,5% 

would expand path environment variable, , use 5 characters begin @ 11th (offset 10) character of expanded result. if length not specified, defaults remainder of variable value. if either number (offset or length) negative, number used length of environment variable value added offset or length specified.



Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -