First post here, so apologies if I don\'t do this quite right.
I\'m trying to output the OS version on a remote Windows PC, but I keep getting unwanted data. Execut
Pipe it to the find command.
@echo off set /p hostname=PC hostname? echo. FOR /F "tokens=1,2 delims==" %%A in ('wmic /node:%hostname% OS get caption /value ^|find /I "caption"') DO echo %%B echo. pause