Поделиться через


CeDeleteRecord (EDB) (Windows Embedded CE 6.0)

1/6/2010

This function deletes a record from a database.

This function does not work with CEDB databases. For more information about CEDB, see CEDB Reference.

Syntax

BOOL CeDeleteRecord(
  HANDLE hDatabase,
  CEOID oidRecord
);

Parameters

  • hDatabase
    [in] Handle to the database from which to delete the record. The database is opened by using the CeOpenDatabaseInSession (EDB) function.
  • oidRecord
    [in] Object identifier of the record to delete. This object identifier must have been generated from EDB, not CEDB.

Return Value

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

Return Value Description

ERROR_INVALID_HANDLE

The hDatabase parameter is set to NULL or equal to INVALID_HANDLE_VALUE.

ERROR_INVALID_PARAMETER

The oidRecord parameter is set to NULL or invalid.

ERROR_NOT_FOUND

The record specified by oidRecord does not exist.

ERROR_SHARING_VIOLATION

Indicates a lock conflict.

Remarks

If the CEDB_AUTOINCREMENT flag was not specified when the database was opened and the record being deleted is the current record, the next read operation that uses the database handle fails. If the CEDB_AUTOINCREMENT flag was specified, the system automatically moves the current seek pointer forward by one.

Requirements

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

See Also

Reference

EDB Functions
CeOpenDatabaseInSession (EDB)