0.9b (c) 1995 Peter Childs
The function retrieves a list of diskette and disk drives on a server.
Syntax
MyRc = NetEnumerate(NETSERVERDISK, 'srvDiskInfo', SrvName)
Parameters
The parameters specified are:
'srvDiskInfo' The REXX variable receiving the result. The variable is divided into:
o srvDiskInfo.0
The number of disk drives available on the server specified
o srvDiskInfo.i
The disk drive name entry i, where the variable i has a value from 1 to srvDiskInfo.0
SrvName The server computer name
Note
The server computer name can be specified as '' for a local server.
Example
/* List disk drives on a server */ call RxFuncAdd 'LoadLsRxutFuncs', 'LSRXUT', 'LoadLsRxutFuncs' call LoadLsRxutFuncs NETSERVERDISK = 150 SrvName = '\\DOMAIN_CONTRLR' myRc = NetEnumerate(NETSERVERDISK, 'srvDiskInfo', SrvName) if myRc <> '0' then do say 'Got error from NetEnumerate() ' myRc call DropLsRxutFuncs exit 9 end if srvDiskInfo.0 = 0 then do say 'No server disk drives' call DropLsRxutFuncs exit 0 end say 'Number of disk drives: ' srvDiskInfo.0 say do i=1 to srvDiskInfo.0 say srvDiskInfo.i end call DropLsRxutFuncs call RxFuncDrop 'LoadLsRxutFuncs' exit 0
Example Output
Number of disk drives: 7 A: B: C: D: E: F: G:
Inf-HTML End Run - Successful