次の方法で共有


CeDeleteDatabaseEx (EDB) (Windows Embedded CE 6.0)

1/6/2010

This function deletes a database that is in a volume that was mounted by using the CeMountDBVolEx (EDB) function.

Syntax

BOOL CeDeleteDatabase( 
  PCEGUID pGuid
  CEOID oid
);

Parameters

  • pGuid
    [in] Pointer to a buffer that contains the CEGUID that represents the mounted database.
  • Oid
    [in] OID of the database to delete. This database must exist in the volume specified by pGuid. This OID is generated by the CeCreateDatabaseWithProps (EDB) function.

Return Value

TRUE indicates success. FALSE indicates failure. To get extended error information, call GetLastError. The following table lists possible values returned by GetLastError:

Return Value Description

ERROR_INVALID_PARAMETER

Indicates one of the following:

  • The pGuid parameter is set to NULL.
  • The oid parameter is set to NULL.

ERROR_NOT_FOUND

The volume specified by pGuid does not exist, or the database specified by oiddoes not exist in the specified volume.

ERROR_SHARING_VIOLATION

The database specified is currently open, and therefore cannot be deleted.

Remarks

A database cannot be deleted if it is open.

Requirements

Header windbase.h
Library coredll.lib
Windows Embedded CE Windows CE 5.0 and later

See Also

Reference

EDB Functions
CeMountDBVolEx (EDB)
CeCreateDatabaseWithProps (EDB)