Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Accessing workgroup names using perl

by vladb (Vicar)
on Jun 19, 2002 at 18:05 UTC ( [id://175790]=note: print w/replies, xml ) Need Help??


in reply to Accessing workgroup names using perl

I'm not a huge expert on Windows NT, but couldn't you run the 'net' command from inside a perl script and simply process the output to get the desired result? Find some detailed info on the 'net' command: here.

my @net_info = `net config`; # @net_info should contain lines of output # produced by the 'net config' command. # I hope they should contain work group info? while (@net_info) { # parse the line here... print "$_\n"; }


_____________________
# Under Construction

Replies are listed 'Best First'.
Re: Re: Accessing workgroup names using perl
by earthboundmisfit (Chaplain) on Jun 19, 2002 at 18:26 UTC
    Perhaps that works on NT4 only?? For Win2K try:
        my @net_info = `net view`;
    
Re: Re: Accessing workgroup names using perl
by caedes (Pilgrim) on Jun 19, 2002 at 19:18 UTC
    You'll only get a list of workgroups (or domains) if you use 'net view /DOMAIN'. This works on Windows 2000.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://175790]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (6)
As of 2024-04-25 11:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found