Platform SDK: Removable Storage Manager |
The ChangeNtmsMediaType function moves the specified PMID to the specified target media pool and sets the PMID's MediaType GUID to the MediaType of the target media pool.
DWORD ChangeNtmsMediaType( HANDLE hSession, LPNTMS_GUID Pmid, LPNTMS_GUID MPoolId );
Value | Meaning |
---|---|
ERROR_ACCESS_DENIED | NTMS_MODIFY_ACCESS to media's media pool is denied. |
ERROR_DATABASE_FAILURE | The database is inaccessible or damaged. |
ERROR_DATABASE_FULL | The database is full. |
ERROR_INVALID_HANDLE | The session handle is invalid or missing. |
ERROR_INVALID_MEDIA_POOL | The media pool ID is invalid. |
ERROR_INVALID_PARAMETER | The media pool or media ID is missing. |
ERROR_NOT_ENOUGH_MEMORY | An allocation failure occurred during processing. |
ERROR_SUCCESS | The function was successful. |
The ChangeNtmsMediaType function uses the same policy for moving media as the MoveToNtmsMediaPool function (UNRECOGNIZED media can only be moved to the FREE Pool).
Windows NT/2000: Requires Windows 2000.
Header: Declared in Ntmsapi.h.
Library: Use Ntmsapi.lib.
Media Services Functions, AddNtmsMediaType, DeleteNtmsMediaType