## Presentation Device Driver Reference for OS/2

[prev][next][parent][TOC]

### Link_Chain_Element - Parameters

new_element_ptr (PDSPINSTL_CHAIN) - input If create_flag is set to 1, this argument will return a pointer to the new element. If create_flag is set to 0, on input this argument points to an existing DSPINSTL data chain element.

create_flag (USHORT) - input The flag that indicates whether the caller wants the function to create a new element or merely link an element into the chain. A value of 1 indicates that a new element should be created and then linked into the chain. A value of 0 indicates that an existing element (pointed to by the new_element_ptr argument) should be linked into the chain.

position_flag (USHORT) - input The flag that indicates where the caller wishes the data chain element to be linked into the data chain. A value of 0 places the element at the head of the chain. A value of 1 places it at the tail of the chain. A value of 2 indicates that the element should be linked in front of the chain element pointed to by the existing_element_ptr argument. A value of 3 indicates that the element should be linked after the chain element pointed to by the existing_element_ptr argument.

existing_element_ptr (PDSPINSTL_CHAIN) - input If the position_flag is set to 2 or 3 on input, this argument points to another data element within the chain.

rc (ULONG) - returns Return codes.

This service function returns the following values:

0 Success
1 Element could not be linked into chain
2 New chain element could not be allocated