No, Win32::Lanman will not return mapped drives, and yes, Win32::Lanman and
Win32::NetAdmin should return similar results on the surface, but if I'm not
mistaken, Win32::Lanman returns an array of hash references with information
about the drives as well, which should let you distinguish between removable
media, etc.

In general, the reason why I go with Win32::Lanman when I can is that you
can usually replace two or three other modules with it, and there is
virtually nothing you can do remotely with the Win32 API that Win32::Lanman
doesn't cover.  The only drawback is that it is SO expansive that you can
get lost in the documentation.

-----Original Message-----
From: Arul, Rex
To: Timothy Johnson; Arul, Rex; 'Shishir K. Singh '
Cc: '[EMAIL PROTECTED] '
Sent: 5/24/02 7:46 AM
Subject: RE: Gettting Drives on Windows

Timothy and Shishir, 

I am not quite sanguine on whether Win32::Lanman returns all the drives
(including mapped-drives). I am sure its
Win32::Lanman::NetServerDiskEnum("servername", \@disks) function returns
the same output as Win32::NetAdmin. BTW, I guess Win32::NetAdmin comes
with default flavor of ActiveState for Windows.

However for the other two, you can get the modules here: 

For Win32::Lanman -->
ftp://ftp.roth.net/pub/ntperl/others/Lanman/
<ftp://ftp.roth.net/pub/ntperl/others/Lanman/>  
For Win32::AdminMisc -->        ftp://ftp.roth.net/pub/ntperl/AdminMisc/
<ftp://ftp.roth.net/pub/ntperl/AdminMisc/>  

Cheers, 
Rex 

-----Original Message----- 
From: Timothy Johnson [ mailto:[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]> ] 
Sent: Friday, May 24, 2002 10:34 AM 
To: 'Arul, Rex '; 'Shishir K. Singh ' 
Cc: '[EMAIL PROTECTED] ' 
Subject: RE: Gettting Drives on Windows 


  
Win32::Lanman has this functionanlity as well. 

-----Original Message----- 
From: Arul, Rex 
To: Shishir K. Singh 
Cc: [EMAIL PROTECTED] 
Sent: 5/24/02 7:22 AM 
Subject: RE: Gettting Drives on Windows 

If it is fixed drives, you can use the Win32::NetAdmin module: 

C:\Perl\rex>perl -MWin32::NetAdmin -e 
"Win32::NetAdmin::GetServerDisks('', 
\@arr); print qq[Fixed Drives in this Machine are: \n];for(@arr){ print 
qq[$_\n];}" 

Fixed Drives in this Machine are: 
A: 
C: 
D: 

Please note that this module does not give Mapped-Drives and it does not

distinguish between hard/floppy/CD drives. Am not sure, if you need 
extended 
functionality, but if you do, I guess there is a module called 
Win32::AdminMisc, with a function to specify type of drives desired.I 
have 
not tried that module, yet. 

Thanks, 
Rex 




-----Original Message----- 
From: Shishir K. Singh [ mailto:[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]> ] 
Sent: Friday, May 24, 2002 10:08 AM 
To: begin begin 
Subject: Gettting Drives on Windows 


Hi, 

Sometime back, someone had posted the module to get the drives on 
Windows 
system on my request. Think it was either Nikola Janceski or Beau Cox. 
Could 
you pls resend the zipped file or the link to it. Appreciate it!! 

Thanks 
Shishir 

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED] 
For additional commands, e-mail: [EMAIL PROTECTED] 


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to