Jump to content

CM QUERYRECORD

From EDM2
Revision as of 01:27, 21 April 2025 by Martini (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This message returns a pointer to the requested RECORDCORE structure.

Note
; If the CCS_MINIRECORDCORE style bit is specified when a container is created, then MINIRECORDCORE should be used instead of RECORDCORE, and PMINIRECORDCORE should be used instead of PRECORDCORE in all applicable data structures and messages.

Syntax

param1
PRECORDCORE pRecord; /* Pointer to the RECORDCORE structure used to search for the next or previous container record. */

param2
USHORT cmd;      /* Command that indicates which container record to retrieve. */
USHORT fsSearch; /* Enumeration order. */

Parameters

pRecord (PRECORDCORE) - Input
Pointer to the RECORDCORE structure used to search for the next or previous container record. If the CMA_FIRST or CMA_LAST attribute is specified, this is ignored.
cmd (USHORT) - Input
Command that indicates which container record to retrieve:
CMA_FIRST: First record in the container.
CMA_FIRSTCHILD: First child record of pRecord specified in param1.
CMA_LAST: Last record in the container.
CMA_LASTCHILD: Last child record of pRecord specified in param1.
CMA_NEXT: Next record of pRecord specified in param1.
CMA_PARENT: Parent of pRecord specified in param1.
CMA_PREV: Previous record of pRecord specified in param1.
fsSearch (USHORT) - Input
Enumeration order. Specifies the enumeration order. This value is one of the following:
CMA_ITEMORDER: Container records are enumerated in item order, first to last.
CMA_ZORDER: Container records are enumerated by z-order, from first record in the z-order to the last record. The last z-order record is the last record to be drawn. This flag is valid for the icon view only.

Returns

pRecord (PRECORDCORE) - returns
Pointer to the RECORDCORE structure for which data was requested.
NULL: No RECORDCORE structures to retrieve.
-1: The container record data was not returned. The WinGetLastError function may return the following error:
PMERR_INVALID_PARAMETERS.
Other: Pointer to the container record for which data was requested.

Remarks

If the cmd parameter has the value of CMA_FIRST or CMA_LAST, the pRecord parameter in param1 is ignored and the first or last record, respectively, in the container is returned.

Depending on the value of the fsSearch parameter, the container records are enumerated in item order or in z-order.

See RECORDCORE or MINIRECORDCORE for a complete list and descriptions of all container record attributes.

Default Processing

The default window procedure does not expect to receive this message and therefore takes no action on it other than to return NULL.