Jump to content

CM INSERTDETAILFIELDINFO

From EDM2
Revision as of 00:47, 21 April 2025 by Martini (talk | contribs) (Created page with "This message inserts one or more FIELDINFO structures into a container control. ==Syntax== <PRE> param1 PFIELDINFO pFieldInfo; Pointer to the FIELDINFO structure or structures to insert.: param2 PFIELDINFOINSERT pFieldInfoInsert; Pointer to the FIELDINFOINSERT data structure.: </PRE> ==Parameters== ;pFieldInfo (PFIELDINFO) - Input : Pointer to the FIELDINFO structure or structures to insert. ;pFieldInfoInsert (PFIELDINFOINSERT) - Input...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This message inserts one or more FIELDINFO structures into a container control.

Syntax

param1
PFIELDINFO pFieldInfo;         /* Pointer to the FIELDINFO structure or structures to insert. */

param2
PFIELDINFOINSERT pFieldInfoInsert; /* Pointer to the FIELDINFOINSERT data structure. */

Parameters

pFieldInfo (PFIELDINFO) - Input
Pointer to the FIELDINFO structure or structures to insert.
pFieldInfoInsert (PFIELDINFOINSERT) - Input
Pointer to the FIELDINFOINSERT data structure.

Returns

cFields (USHORT) - returns
Number of structures.
0: The FIELDINFO structure or structures were not inserted. The WinGetLastError function may return the following errors:
PMERR_INVALID_PARAMETERS
PMERR_INSUFFICIENT_MEMORY
PMERR_FI_CURRENTLY_INSERTED
Other: The number of FIELDINFO structures in the container.

Remarks

The pFieldInfoInsert parameter is used to insert FIELDINFO structures into the container. The pFieldInfoOrder field of the FIELDINFOINSERT data structure is used to place FIELDINFO structures into the container in order, relative to the other structures. Specifying the CMA_FIRST attribute places the FIELDINFO structure at the front of the list of structures. If the CMA_END attribute is specified, the FIELDINFO structure is placed at the end of the list of structures. Otherwise, if the value of the pFieldInfoOrder field is a pointer to a FIELDINFO structure, the structure being inserted is placed after this structure.

If the value of the cFieldInfoInsert field of the FIELDINFOINSERT data structure is greater than 1, a linked list of FIELDINFO structures is inserted in the order specified by the pFieldInfoOrder field. Here, the pFieldInfo parameter points to the first of a linked list of FIELDINFO structures. This list of structures is linked together as they were when the FIELDINFO structures were allocated.

If one FIELDINFO structure is to be inserted, the cFieldInfoInsert field has a value of 1 and the pFieldInfo parameter points to the FIELDINFO structure to be inserted.

After the FIELDINFO structures have been inserted, if the fInvalidateFieldInfo field of the FIELDINFOINSERT data structure is FALSE, the CM_INVALIDATEDETAILFIELDINFO message must be sent to update the display with the inserted structures.

If the CCS_VERIFYPOINTERS style bit is set and the pFieldInfo parameter contains a pointer to a FIELDINFO structure that is currently inserted, the PMERR_FI_CURRENTLY_INSERTED error is set and no FIELDINFO structures are inserted.

Default Processing

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