G
Guest
Hi,
I'm writing a batch file trying to get the hostname of a local machine and
pass it on as a variable within the same file. Let's say in test.bat
@echo off
set n=
hostname
set n= (host name)
But, somehow it is not working. Any suggestion on how to get the hostname
and pass it on to a variable.
Thanks,
Mike
I'm writing a batch file trying to get the hostname of a local machine and
pass it on as a variable within the same file. Let's say in test.bat
@echo off
set n=
hostname
set n= (host name)
But, somehow it is not working. Any suggestion on how to get the hostname
and pass it on to a variable.
Thanks,
Mike