Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!mcsun!ukc!slxsys!dircon!uad1020 From: uad1020@dircon.uucp Newsgroups: comp.sys.mac.programmer Subject: Resource Files Message-ID: <1990Aug23.152926.5906@dircon.uucp> Date: 23 Aug 90 15:29:26 GMT Sender: uad1020@dircon.uucp Reply-To: uad1020@dircon.uucp () Organization: The Direct Connection, UK Lines: 37 I have been writing a program recently which has been creating a lot of grief. I am using Think C 4.0 and its Class Libraries. The program takes a text file and extracts various sections from it which are assigned into individual folders. In a folder are a number of files which are logically linked and each file has a data and resource fork. The data has the actual text that I hook out and the resource fork has an index to its data fork. This may well be a bad way of dealing with this situation but it is not the problem. My problem is that when my application has to create a new folder (as it always checks before it tries to write to it), it has a strange repercussion a little later on. The part of my application that writes the document back does two stages ... firstly it creates an instance of CDataFile and writes that back to the correct place, and then straight afterwards it writes its index details back to the resource file. My problem is that it does this correctly except when a folder has been created earlier ... instead it creates it in the folder my application was in when the new folder was being created. Um ... does that make sense? All my folders are in the right order and all my data files are in the right place. Are there any known effects of PBDirCreate which could cause this? Your help is very much appreciated. Ian -- ///////////////////////////////////////////////////////////////// // Ian Cottee ----- zobbo@cix.uucp // // uad1020@dircon.uucp // /////////////////////////////////////////////////////////////////