Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!henry.jpl.nasa.gov!elroy.jpl.nasa.gov!cit-vax!oxy!sonenbli From: sonenbli@oxy.edu (Andrew D. Sonenblick) Newsgroups: comp.sys.mac.programmer Subject: getting the necessary vRefNum (once we find the flashlight!)... Message-ID: <48131@tiger.oxy.edu> Date: 27 Aug 89 02:06:52 GMT Organization: Occidental College, Los Angeles, CA 90041 Lines: 20 Ok, you're a happy-go-lucky application on a Macintosh, eager to please your use in any way you can. Suddenly, your user types in the name of a file which s/he _knows_ is on the current volume, and wants you to return the vRefNum that corresponds with that file--in other words, the vRefNum such that the call SetVol(0,vRefNum); would ensure that the call OpenResFile(&fileName); would not return FileNotFound error. What would your code look like... keeping in mind that no calls to SFPut/GetFile are ever executed... Also, as an Apple Macintosh, you know that all those knowledgable users or programmers who can provide the necessary code will feel an incredible amount of personal joy and a true sense of self worth if they just take the time to share their solution code snipet with those of less knowledge and experience! Not only that, it would make you a Happy Mac! sonenbli@oxy.edu