This allows me to see all of the workstations and servers that are not
hidden.  The Win32::AdminMisc::GetMachines allowed me to see the
workstations that were hidden as well.

On our domain, All of the workstations are hidden and only the Servers can
be browsed.

Tad

-----Original Message-----
From: VANHERP Wim [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 18, 2003 2:09 AM
To: 'Tad Chrapko'
Subject: RE: Win32::AdminMisc



you can use getservers ,with  SV_TYPE_NT it points it to workstations 


Win32::NetAdmin::GetServers($pdc, $domain,SV_TYPE_NT, [EMAIL PROTECTED]);

see also 

http://www-fp.mcs.anl.gov/~stace/Papers/NTLisa1999/paper.html

I had found somewhere (at microsoft) a list of the meaning of the constants
like SV_TYPE_NT and others, but i do not find it for the moment

Wim Vanherp
tel : 5100
GSM :0478 88 32 03


> ----------
> From:         Tad Chrapko[SMTP:[EMAIL PROTECTED]
> Sent:         donderdag 18 september 2003 0:45
> To:   '[EMAIL PROTECTED]'
> Subject:      Win32::AdminMisc
> 
> I'm having a problem getting Dave Roth's Win32::AdminMisc to work
> properly.
> 
> I have created a script that I have tested on Perl 5.6 and on Perl 5.8.
> On
> Perl 5.8 it returns: Failed With: The specified procedure could not be
> found.  On Perl 5.6 it is successful if I use Win32::AdminMisc ver.
> 20000708, but none of the 2003 versions.
> 
> It appears that "GetMachines" does not work on Perl 5.8.  The version of
> Win32::AdminMisc is 0.2003.07.14
> 
> This is the script that I am using.
> 
> use Win32::AdminMisc;
> 
> my $domain = "DOMAIN";
> print "Generating domain list for $domain ...\n";
> Win32::AdminMisc::GetMachines($domain, UF_SERVER_TRUST_ACCOUNT |
> UF_WORKSTATION_TRUST_ACCOUNT, [EMAIL PROTECTED], "") ||die "Failed With: ",
> Win32::FormatMessage(Win32::GetLastError());
> $domnum = 0;
> foreach (@domlist) {
>    print "$_\n";
>    $domnum = $domnum+1;
> }
> print "List of $domain generated $domnum systems.\n";
> 
> 
> Does anyone else have this problem?  Is there any way around it.
> 
> 
> Tad Chrapko
> Internal Technology Services (ITS)
> City of St. Albert
> mailto:[EMAIL PROTECTED]
> http://www.city.st-albert.ab.ca
> Tel: 780-459-1666
> T8N 3Z9
> 
> The information contained in this e-mail is intended for the addressee
> only.
> Any other distribution, coping or disclosure in whole or in part by any
> other person is prohibited. If you have received this e-mail in error,
> please notify me immediately and delete any electronic and any hard
> copies.
> 
> 
> _______________________________________________
> Perl-Win32-Admin mailing list
> [EMAIL PROTECTED]
> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
> 
> 
> 
*** Disclaimer ***
Deze e-mail, met eventuele bijlagen, is alleen bestemd voor de persoon of
organisatie aan wie hij gericht is en, in voorkomend geval, alleen voor het
daarin opgegeven doel of gebruik.  Hij kan vertrouwelijke informatie
bevatten en/of persoonlijke standpunten die niet noodzakelijk met die van de
VRT stroken.  Elk gebruik van deze informatie (zoals bewerken, doorsturen,
geheel of gedeeltelijk reproduceren of verspreiden in welke vorm ook) door
anderen dan de geadresseerde, is verboden.  Hebt U deze e-mail per
vergissing ontvangen, meld dat dan a.u.b. aan de VRT en wis de e-mail.
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to