| |
BMeX
Posts: 6
Score: 0
Joined: 12/10/2007
Status: offline
|
Hello Everybody! I already wrote a thread like this, but i do not get ahead with the other reason. So, I have to get the hostname of my primary dns server. First I will identify the IP-Adress of my primary dns - Thats no problem, it works. Then i want to have the hostname, so i have to do a nslookup to the ip address. I do this with the following code: Set oShell = CreateObject("Wscript.Shell") Set oExec = oShell.Exec("nslookup " & sPrimaryDNS_IP) Do Until oExec.StdOut.AtEndOfStream sNsLookUp_ReturnValue = oExec.StdOut.ReadAll Loop Set oExec = Nothing MsgBox sNsLookUp_ReturnValue This code works too, BUT everytime I execute this, a dos box appears. finally this code will be used as a part of a logonscript and then it annoys, if a dos box appears everytime you log in. Now i want hide this dos box, but i do not know how i can do that? If it is possible, it would be very nice if i can do this without any tools, only with vbscript. As far as i know, if i execute this command with "Run", it is not possible to get a return value to edit? I tried a WMI-Procedure too, but fot this i need to be an administrator, that shuldn't be like this. I hope you can help me, i'm on the ropes :-) Thanks, KR BMeX P.S. I'm sorry, but i hope you can understand me or my problem :-) my english is not the best as you see.
|
|