Represents a NetWare volume.
Gives the size in bytes, of a specified block.
Object.BlockSize
Long.
Read-only.
See for a sample in Example.
Returns an extended information object that contains additional information about the volume.
Object.ExtendedVolInfo
ExtendedVolInfo.
Read-only.
Obj is a placeholder for the extended volume information object.
See for a sample in Example.
Indicates the number of directories that can be created, based on the difference between the total allowable number of directories and the number of directories already created.
object.FreeDir
Long.
Read-only.
See for a sample in Example.
Indicates the available space, in kilobytes, on a specified volume.
object.FreeSpace
Long.
Read-only.
See for a sample in Example.
Indicates whether the volume is hashing in the file server memory.
object.Hashing
Boolean. Returns TRUE if the volume is hashing else returns FALSE.
Read-only.
This property returns FALSE for non-hashing file server memory.
See for a sample in Example.
Determines whether the specified volume is already mounted.
object.Mounted
Boolean. Returns TRUE if the volume is already mounted else returns FALSE.
Read-only.
See for a sample in Example.
Gives the name of the volume.
object.Name
String.
Read-only.
See for a sample in Example.
Gives the total space that can be purged on the specified volume.
object.PurgableSpace
Long.
Read-only.
See for a sample in Example.
Indicates the specified volume can be physically removed from the file server.
object.Removable
Boolean. Returns TRUE if the volume can be removed else returns FALSE.
Read-only.
This property returns FALSE for volumes that cannot be physically removed.
See for a sample in Example.
Gives the total number of directories on the volume.
object.TotalDir
Long.
Read-only.
See for a sample in Example.
Gives the total space, in kilobytes, on the specified volume.
object.TotalSpace
Long.
Read-only.
This sample gives all the information related to volume Sys.
On Error Resume Next
’Get all information about Sys
Set volmgr = CreateObject ("UCX:VolumeMgr")
Set volumes = volmgr.Volumes
Set volume = Volumes.Element("Sys")
If (Err.Number = 0) then
Print ("Block Size is "&volume.BlockSize)
Print ("Volume Name is "&volume.Name)
Print ("The number of directories that can be created "&
volume.FreeDir)
Print ("The available space in KB: "&volume.FreeSpace)
Print ("The volume is hashing "&volume.Hashing)
Print ("The mounted status is "&volume.Mounted)
Print ("The purgable space in KB "&volume.PurgableSpace)
Print ("The removable status is "&volume.Removable)
Print ("The total number directories in this volume
"&volume.TotalDir)
Print ("The total space on the volume in KB
"&volume.TotalSpace)
Else
Print("Error is " & Err.Description)
Endif
Dismounts a NetWare volume.
object.Dismount
None.
Boolean. Returns TRUE if successful. Else returns FALSE.
This example dismounts from volume Barney.
Set nds1 = CreateObject("ucx:NWDir")
’Log in to an account with supervisory rights
nds1.Login("username", "password")
If (Err.Number = 0) then
’Get all information about Barney
Set volmgr = CreateObject ("UCX:VolumeMgr")
Set vols = volmgr.Volumes
Set volume = Vols.Element("Barney")
volume.Dismount()
If (Err.Number = 0) then
Print("Volume dismounted")
Else
Print("Dismount failed " & Err.Description)
Endif
ndslog.Logout()
Else
Print("Login failed " & Err.Description)
Endif
Returns the VolumeRestrictions object for a user. The VolumeRestrictions object contains the information about the space restriction for a user on the specified volume.
Object.GetSpaceRestriction()
None.
VolumeRestrictions.
obj is a placeholder for the resulting VolumeRestrictions object.
This example returns the VolumeRestrictions object for the user TestUser.
On Error Resume Next
Set volmgr = CreateObject ("UCX:VolumeMgr")
Set volumes = volmgr.volumes
Set volume = Volumes.Element("Sys")
If (Err.Number = 0) then
Set RestrictionsObj = volume.GetSpaceRestriction ()
If (Err.Number = 0) then
Set restr = RestrictionsObj.Element("guest")
If (Err.Number = 0) then
Print "The restriction volume limit for "&restr.Name
& " is " &restr.VolumeLimit
Else
Print("Failed to find restriction for the specified
user " & Err.Description )
Endif
Else
Print ( "Failed to get restrictions object " &
Err.Description )
Endif
Else
Print ( "Failed to find the volume " & Err.Description )
Endif