[This is preliminary documentation and subject to change.]
The DisableNtmsObject function disables the specified RSM object.
DWORD WINAPI DisableNtmsObject(
HANDLE hSession,
DWORD dwType,
LPNTMS_GUID lpObjectId
);
Value | Meaning |
---|---|
NTMS_DRIVE | An RSM drive. |
NTMS_LIBRARY | An RSM library unit. |
NTMS_PHYSICAL_MEDIA | A physical media object (a tape, optical disk, CD, or magnetic cartridge). |
The DisableNtmsObject function queues a disable command with the specified object. If RSM is busy, the command can take some time to complete. The application can wait for the command to complete by examining the enabled field of the object.
When the medium is disabled, RSM renders all of the media's partitions and associated logical media unavailable. All requests to disabled media returns an error.
To remove a drive or media changer from service the drive or media changer must first be disabled.
All objects contained by a disabled object are also disabled. For example, disabling a piece of physical media disables all partitions. However, RSM does not set the disabled bit of the partition, and functions such as GetNtmsObjectInformation continue to work.
Whenever possible, when a drive is disabled, the medium in the drive is removed and placed in its slot.
Windows NT: Requires version 5.0 or later.
Windows: Unsupported.
Windows CE: Unsupported.
Header: Declared in ntmsapi.h.
Import Library: Use ntmsapi.lib.
Object Management Functions, EnableNtmsObject