Apple Network Setup Network Card User Manual


 
CHAPTER 3
Network Setup Reference
Network Setup Functions 69
that are available. On output, itemCount points to the number of
areas for which information was actually returned, which may
be less that expected if areas were deleted between calling
OTCfgGetAreasCount (page 68) and calling OTCfgGetAreasList.
areaID On input, an array of elements of type CfgAreaID (page 98) that
is large enough to hold the number of area IDs specified by
itemCount. On output, each array element contains an area ID. If
you don’t want to get area IDs, set areaID to NULL.
areaName On input, an array of elements of type Str255 that is large
enough to hold the number of area names specified by
itemCount. On output, each array element contains an area
name. The area name in the first element corresponds to the area
ID in the first element of the array specified by areaID, and so
on. If you don’t want to get area names, set areaName to NULL.
function result A value of noErr indicates that OTCfgGetAreasList returned
successfully. For a list of other possible result codes, see “Result
Codes” (page 110).
DISCUSSION
The OTCfgGetAreasList function obtains the IDs and names of areas in the
database and stores this information in two arrays: one containing area IDs and
the other containing area names. Each area ID and area name pair identifies an
area in the database.
When you allocate the arrays for the areaID and areaName parameters, be sure to
allocate enough elements to hold the number of areas returned by
OTCfgGetAreasCount (page 68). The actual number of items returned in each
array may be lower than the number returned by OTCfgGetAreasCount (page 68)
if areas have been deleted in the meantime.