Dummy me.....got it...sorry to bother you all.
solution was (for anyone that cares)
set /p usrinput=Enter computer name or ip address: %=%
cmd.exe /c wmic /node:%input% computersystem get username
pause
forgot the cmd.exe and had some "extra spaces"
Hi all....not sure if this is even in the correct place or not - if not KINDLY guide me in the right direction and I will get it there.
I would like to use WMIC in a batch file or vbscript. I need to be able to enter a computer name or ip address and return the user name. The following works...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.