If you are on the road to Carbon you need to switch to a minimum of FSSpecs (and preferably FSRefs) unless you have some good reason for using the parameter block stuff. The standard toolbox call for deleting a file using an FSSpec is: Dim as OSStatus ignore ignore = fn FSpDelete (yourFSSpecHere) The FILES$ verb returns FSSpecs and there are utility FNs to convert to FSSpecs (e.g. FN FBMakeFSSpec(vRef,dirID,name, anFSSpec )) If you need a better example just shout. Alain's MoreXFiles has lots of advanced file handling examples in it but that may not be necessary depending on what the programs need. Brian S. On Mar 10, 2006, at 8:59 PM, Joe Lertola wrote: > Hi all, > > It has been several years since I have done any serious > programming. The coming demise of the classic environment has > prompted me to start updating several programs I have written. I am > getting an error on this function that I can seem to find an answer > to. > > CLEAR LOCAL MODE > DIM PBlk;128 > LOCAL FN KillFile(FileName&,Vol%) > 'tron break > & @PBlk +_ioNamePtr,FileName& > % @PBlk +_ioVRefNum,Vol% > ioErr=FN DELETE(@PBlk) > END FN = ioErr > > The error message is that the function FN DELETE must be defined > before using. > > I got this function from the FutureBasic examples files and it has > worked well for many years in the classic version of the program. > Can anyone offer a suggestion on how to get this function to work > under Carbon or offer an alternative way to delete a file? > > Thanks for any help, > > -Joe Lertola > > -- >