Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!wuarchive!udel!haven.umd.edu!cs.wvu.wvnet.edu!cerc.wvu.wvnet.edu!blackwater!vrm From: vrm@blackwater.cerc.wvu.wvnet.edu (Vasile R. Montan) Newsgroups: comp.sys.mac.programmer Subject: When you AddResource, does the Handle now point to a resource? Message-ID: <1648@babcock.cerc.wvu.wvnet.edu> Date: 27 Apr 91 02:30:24 GMT Sender: news@cerc.wvu.wvnet.edu Reply-To: un020070@vaxa.wvnet.edu Lines: 27 I am writing a program which installs resources into files. Suppose I have the following code: procedure InstallResource; var MyHandle : Handle; begin MyHandle^^ := {Whatever data to be put in the resource} AddResource (MyHandle, rsrcType, rsrcID, rsrcName); {...etc....} end; As I understand it, I use DisposHandle to get rid of one of my own handles, but I use ReleaseResource to get rid of a resource. Assuming that I have written my code as above, should I now say "DisposHandle(MyHandle)" or "ReleaseResource(MyHandle)"? If I want to stop treating it as a resource, should I DetachResource it, or is it already not a resource? If it is a resource, do I have to explicitly call UpdateResFile (or WriteResource) before releasing it, or does calling ReleaseResource automatically write it out? Thank you! --Kurisuto un020070@vaxa.wvnet.edu