Apple Network Setup manual OTCfgGetPrefsTOCCount

Models: Network Setup

1 184
Download 184 pages 5.56 Kb
Page 88
Image 88
OTCfgGetPrefsTOCCount

C H A P T E R 3

Network Setup Reference

DISCUSSION

The OTCfgSetPrefs function sets the preference represented by prefsType to the value specified by data.

The accessID parameter must have been created by calling OTCfgOpenPrefs (page 84) with the writer parameter set to TRUE; otherwise, OTCfgSetPrefs returns the error kCfgErrLocked.

OTCfgGetPrefsTOCCount

Gets the number of preferences in an entity.

OSStatus OTCfgGetPrefsTOCCount (CfgEntityAccessID accessID.

ItemCount *itemCount);

accessID On input, a value of type CfgEntityAccessID (page 100), obtained by previously calling OTCfgOpenPrefs (page 84) that identifies the entity whose preferences are to be counted.

itemCount On input, a pointer to a value of type ItemCount. On output, itemCount contains the number of preferences in the entity represented by accessID.

function result A value of noErr indicates that OTCfgGetPrefsTOCCount returned successfully. For a list of other possible result codes, see “Result Codes” (page 110).

DISCUSSION

The OTCfgGetPrefsTOCCount function gets the number of preferences in the entity represented by accessID.

You should call OTCfgPrefsTOCCount to find out how many preferences are present before calling OTCfgGetPrefsTOC (page 89).

88Network Setup Functions

Page 88
Image 88
Apple Network Setup manual OTCfgGetPrefsTOCCount