bdfp1m1cProgramming Concepts and Reference

dfkey-Activate a Key List

Use this function to activate a key list that is used by subsequent functions that access the specified file. See Specifying Logical Records (LRECs) Using Keys for more information about keys.

Format

void dfkey(dft_fil *file,
           dft_kyl *key_list)
void dfkey_nbr(dft_fil *file,
           dft_kyl *key_list, short int n)

file
is a pointer to the base address of the SW00SR slot (defined in c$sw00sr.h) of the subfile that you want to access and is returned by the dfopn function.

key_list
is a pointer to the key list (SW01SR).

n
is the number of keys (1-180) that you have set up in the key list.

Entry Requirements

None.

Normal Return

None.

Error Return

 See Identifying Return Indicators and Errors for information about how to check the error indicators. 

Programming Considerations

Examples

See Setting up a Key List with Less than Six Keys and Setting up a Key List in the Range 1-180 for examples of how to set up a key list.

Related Functions