GetVolumeName

Returns a volume name for a volume

Local Servers:nonblocking
Remote Servers:blocking
NetWare Server:3.x, 4.x, 5.x, 6.x
Platform:NLM
SMP Aware:No
Service:Volume

Syntax

   #include <nwdir.h> 
    
    int GetVolumeName (  
       int     volumeNumber, 
       char   *volumeName);
   

Parameters

volumeNumber
(IN) Specifies the number of the volume slot (0-254 for NetWare 5.x and 6.x, 0-63 for NetWare 3.1 and 4x, 0-31 for previous versions). Even though the Volume Mount Table is 256 slots in size (0-255), the system reserves 255 as an invalid volume ID.
volumeName
(OUT) Points to the buffer in which to return the volume name (maximum 16 characters, including the NULL terminator).

Return Values

Decimal

Hex

Constant

0

(0x00)

ESUCCESS

152

(0x98)

ERR_VOLUME_DOES_NOT_EXIST

Remarks

The volumeNumber identifies the volume on the server’s Volume Table, which contains information about each volume on the server.

If a volume is mounted in the referenced slot in the Volume Table, its name is returned in the volumeName parameter. If a volume is not mounted in that slot, the output parameter volumeName is NULL.

ESUCCESS is returned when the volumeNumber is valid, even if the volume is not mounted. In that case, you need to test for volumeName being valid.

An error is returned when an invalid volumeNumber is passed in.

See Also

GetVolumeInformation, GetVolumeInfoWithNumber, GetVolumeNumber, GetVolumeStatistics