Xref: utzoo comp.sys.mac.hypercard:1561 comp.sys.mac:27120 Path: utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!cornell!biar!trebor From: trebor@biar.UUCP (Robert J Woodhead) Newsgroups: comp.sys.mac.hypercard,comp.sys.mac Subject: Re: Launching applications from HyperCard Keywords: Floppy only Message-ID: <142@biar.UUCP> Date: 22 Feb 89 05:06:52 GMT References: <1600@ucqais.uc.edu> Reply-To: trebor@biar.UUCP (Robert J Woodhead) Followup-To: comp.sys.mac.hypercard Organization: Biar Games, Inc. Lines: 18 In article <1600@ucqais.uc.edu> rainwatr@ucqais.uc.edu (Donald J. Rainwater) writes: > After all this introductory information, my question is this. Is >there a way to limit the capabilities of the file dialog box? You will have to use an XCMD that lets you put up a custom SFGetFile dialog. In it you will define a custom fileFilter proceedure (see IM I-517 for info on the standard file package). This procedure will vote "yea" or "nay" on any particular file. The filefilter is pased a pointer to a parameter block that contains the contents of a GetFileInfo call on the file. Call this pointer Info. Info^.ioVRefnum contains the volume reference number of this file. Use that to call PBHGetVolInfo. the ioVDRefNum field contains the driver number of the volume (see IM IV-123,124). If this is -5, it is the ".SONY" floppy disk driver [WARNING:I don't know if the new high density floppies use the same driver]. So you return TRUE if ioVDRefNum=-5, and FALSE otherwise. This means your user can click the drive button all he wants, but will never see any applications on non-floppy drives!