CeUnmountDBVol (EDB)
A version of this page is also available for
4/8/2010
This function unmounts a volume that was previously mounted with the CeMountDBVolEx (EDB) function.
Syntax
BOOL CeUnmountDBVol(
PCEGUID pGuid
);
Parameters
- pGuid
Specifies the CEGUID structure of the mounted volume to be unmounted. You can mount a volume with CeMountDbVolEx.
Return Value
TRUE indicates success. FALSE indicates failure. To get extended error information, call GetLastError. The following table shows possible values.
Return Value | Description |
---|---|
ERROR_INVALID_PARAMETER |
The pGuid parameter is set to NULL. |
ERROR_NOT_FOUND |
The volume identified by pGuid is not currently mounted. |
Remarks
This function is used to unmount a volume that was previously mounted with CeMountDbVolEx. A single database volume can be mounted more than once by different applications. Each time the volume is mounted, a reference count is incremented. A mounted database volume does not fully unmount and close until all applications that mounted the volume call this function. When a volume is unmounted, all cached data is flushed.
After calling this function, pGuid ** becomes invalid. As a result, if you call CeEnumDBVolumes (EDB) after unmounting the volume, the call fails.
Note
If there are open handles on databases within a volume, CeUnmountDbVol does not unmount the volume, but still returns TRUE.
Requirements
Header | windbase.h |
Library | coredll.lib |
Windows Embedded CE | Windows CE 5.0 and later |
Windows Mobile | Windows Mobile Version 5.0 and later |