Important: The information in this document is obsolete and should not be used for new development.
AGFileGetIndDB
Use theAGFileGetIndDB
function to obtain the file system specification record of a guide file located in a specified folder.
OSErr AGFileGetIndDB (short vRefNum, long dirID, AGFileDType databaseType, Boolean wantMixin, short dbIndex, FSSpecType *fileSpec);
vRefNum
- The volume reference number of the volume on which the guide file is located.
dirID
- The directory ID of the directory where the guide file is located.
databaseType
- The guide file type. Use these constants to specify the type of guide file:
enum { kAGFileDBTypeAny = 0,/*any guide file*/ kAGFileDBTypeHelp = 1,/*Help*/ kAGFileDBTypeTutorial = 2,/*Tutorial*/ kAGFileDBTypeShortcuts = 3,/*Shortcuts*/ kAGFileDBTypeAbout = 4,/*About*/ kAGFileDBTypeOther = 8 /*Other*/ };
wantMixin
- A flag. Specify
TRUE
if the desired guide file is a Mixin guide file. SpecifyFALSE
if the guide file is not a Mixin guide file.dbIndex
- A number representing the guide file index. To access the first guide file of the specified type in the folder, set this parameter to 1. To access the second guide file of this type, specify 2, and so on.
- fileSpe
c
- A pointer to a file system specification record. On return, this parameter refers to the file system specification record for the guide file.
DESCRIPTION
TheAGFileGetIndDB
function returns, through itsfileSpec
parameter, the file system specification record for the specified guide file. You can callAGFileGetIndDB
repetitively to access the file system specification record for all of the guide files in a folder. To access all of the guide files, increment thedbIndex
parameter by 1, until the value of thedbIndex
parameter is equal to the number of guide files of the requested type in the folder, or until the function result is nonzero.RESULT CODES
noErr 0 No error dirNFErr -12 Directory not found or incomplete pathname nsvErr -35 Volume doesn't exist SEE ALSO
After obtaining a guide file's file system specification record, you can get information about the guide file by using the functions described in "Getting Information About Guide Files" beginning on page 9-22. You can also open a guide file, as described next.