SFPGetFile
Call theSFPGetFileprocedure when your application requires more control over the Open dialog box than is possible usingSFGetFile.
PROCEDURE SFPGetFile (where: Point; prompt: Str255; fileFilter: FileFilterProcPtr; numTypes: Integer; typeList: SFTypeList; dlgHook: DlgHookProcPtr; VAR reply: SFReply; dlgID: Integer; filterProc: ModalFilterProcPtr);
where- The upper-left corner of the dialog box, in global coordinates.
prompt- Ignored.
fileFilter- A pointer to an optional file filter function, provided by your application, through which
SFPGetFilepasses files of the specified types.numTypes- The number of file types to be displayed. If you specify a
numTypesvalue of -1, the first filtering passes files of all types.typeList- A list of file types to be displayed.
dlgHook- A pointer to your dialog hook function, which handles item selections received from the Dialog Manager. Specify a value of
NILif you have not added any items to the dialog box and want the standard items handled in the standard ways.reply- The reply record, which
SFPGetFilefills in before returning.dlgID- The resource ID of a customized dialog template.
filterProc- A pointer to your modal-dialog filter function, which determines how
theModalDialogprocedure filters events when called by theSFPGetFileprocedure. Specify a value ofNILif you are not supplying your own function.DESCRIPTION
TheSFPGetFileprocedure is an alternative toSFGetFilewhen you want to display
a customized Open dialog box or handle the default dialog box in a customized way. During the dialog,SFPGetFilegets and handles events (possibly with the assistance of application-defined callback routines) until the user completes the interaction, either by selecting a file to open or by canceling the open operation.SFPGetFilereturns the user's input in a record of typeSFReply.ASSEMBLY-LANGUAGE INFORMATION
The trap macro and routine selector forSFPGetFileare
Trap macro Selector _Pack3 $0004 SPECIAL CONSIDERATIONS
BecauseSFPGetFilemay move memory, you should not call it at interrupt time.
Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help