Jul 30, 2004 #1 yert33 Programmer Joined Feb 19, 2002 Messages 255 Location US Is there a more elegant way to do an nslookup from within VFP than: ! nslookup &address > ns.txt then parsing the ns.txt file for the name using low level file functions? THX.
Is there a more elegant way to do an nslookup from within VFP than: ! nslookup &address > ns.txt then parsing the ns.txt file for the name using low level file functions? THX.
Jul 30, 2004 1 #2 craigsboyd IS-IT--Management Joined Nov 9, 2002 Messages 2,839 Location US Windows scripting provides for this: Code: loShell = CreateObject("WScript.Shell") loScriptExec = loShell.Exec("nslookup 192.168.1.149") lcNsLookup = loScriptExec.StdOut.ReadAll() ?lcNsLookup craig1442@mchsi.com"Whom computers would destroy, they must first drive mad." - Anon Upvote 0 Downvote
Windows scripting provides for this: Code: loShell = CreateObject("WScript.Shell") loScriptExec = loShell.Exec("nslookup 192.168.1.149") lcNsLookup = loScriptExec.StdOut.ReadAll() ?lcNsLookup craig1442@mchsi.com"Whom computers would destroy, they must first drive mad." - Anon
Jul 30, 2004 Thread starter #3 yert33 Programmer Joined Feb 19, 2002 Messages 255 Location US B-E-A-utiful. Thanks cb... Upvote 0 Downvote
Jul 30, 2004 Thread starter #4 yert33 Programmer Joined Feb 19, 2002 Messages 255 Location US Where might I find a Windows scripting reference? I'm thinking I might use something other than ReadAll() to get only the server name?? Thanks again Upvote 0 Downvote
Where might I find a Windows scripting reference? I'm thinking I might use something other than ReadAll() to get only the server name?? Thanks again
Jul 31, 2004 #5 Mike Gagnon Programmer Joined Apr 6, 2002 Messages 8,067 Location CA yet33 Where might I find a Windows scripting reference? Click to expand... Windows Script Host Mike Gagnon If you want to get the best response to a question, please check out FAQ184-2483 first. Upvote 0 Downvote
yet33 Where might I find a Windows scripting reference? Click to expand... Windows Script Host Mike Gagnon If you want to get the best response to a question, please check out FAQ184-2483 first.