$computername = [System.Net.Dns]::GetHostByName("youralias")Write-Host $computername.HostName.substring(0,$computername.HostName.IndexOf("."))
Awesome! Thanks!
Hello!Could you help?I would need the cname (alias) from the hostname.Is it possible?thanks in advance,Balazs
Great posst
Post a Comment
3 comments:
Awesome! Thanks!
Hello!
Could you help?
I would need the cname (alias) from the hostname.
Is it possible?
thanks in advance,
Balazs
Great posst
Post a Comment