How to programatically obtain NET VIEW results

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm trying to programatically (within Access) issue a Net View command. I
need to obtain and manipulate (for example display in a list) the resulting
list of machines on the network. Issuing a Shell("Net View > pcnames.dat")
does not redirect the results to a file.

Thanks

(e-mail address removed)
 
DBSmith said:
I'm trying to programatically (within Access) issue a Net View command. I
need to obtain and manipulate (for example display in a list) the resulting
list of machines on the network. Issuing a Shell("Net View > pcnames.dat")
does not redirect the results to a file.

You can create a batch file that issues the command with a file redirect
and then use shell to execute the batch file.

(Odd that the redirect directly in the shell command doesn't work though)
 
I
need to obtain and manipulate (for example display in a list) the
resulting list of machines on the network

Wouldn't the scripting Network object be easier:

Set wshNetwork = CreateObject("WScript.Network")

collDrives = wshNetwork.EnumNetworkDrives


and so on.

Hope that helps


Tim F
 
Back
Top