PRODUCT : Borland C++ NUMBER : 731 VERSION : 2.0 OS : DOS DATE : October 19, 1993 PAGE : 1/2 TITLE : Project File Corruption This information is provided for people who are using the Integrated Development Environment (IDE) provided with Borland C++ or Turbo C++ versions 1.0 and later. This information may apply to any strange behavior experienced while working in the IDE, but it is more specifically for 'win errors' and unexplained GP faults received while working within the IDE. The IDE in Borland C++ and Turbo C++ maintain an image of the IDE in memory. This image contains information about the windows on the desktop, the files that are open, the switches that are set in the IDE, etc. By default when a program is run from the IDE all of the information concerning the current image of the IDE is saved to disk in the appropriate configuration files. If you are not using a project file with your program this image is stored in the TCCONFIG.TC, TCDEF.DSK and TCDEF.DPR ( or TCCONFIG.TC, TCDEFW.DSK and TCDEFW.DPR for the Windows-Hosted IDEs ) files located in your BIN directory (normally TC\BIN, BORLANDC\BIN or TCWIN\BIN ). Additionally if you are using Borland C++ and have pre-compiled headers turned on there will be a TCDEF.SYM file in the same BIN directory. These are your default configuration files and are created for you if they do not already exist. When the IDE is run it looks for TCCONFIG.TC in the current directory first. If it doesn't find one there it then looks in the BIN directory. They will be created using all of the system defaults that your compiler was shipped with unless you have run TCINST or BCINST to modify the defaults. All project files that you create will inherit the information contained in the above listed files with the exception of the TCDEF.SYM file, which is created during the first compilation using the new project file. When you create a project file the system creates a .prj and a .dsk in the current directory. Additionally if you are using Borland C++ and have pre-compiled headers turned on there will be a .SYM file in the current directory after the first compilation using the new project file. Ensure that you have not put any header (*.H) files in the project file. When experiencing any behavior in the IDE that appears to be incorrect on the part of the IDE the following procedure should be followed: PRODUCT : Borland C++ NUMBER : 731 VERSION : 2.0 OS : DOS DATE : October 19, 1993 PAGE : 2/2 TITLE : Project File Corruption 1. If you are in the IDE exit out using ALT-X (don't shell out) or ALT-F4( Windows-Hosted ). 2. Go to the directory (current or BIN) containing the TCCONFIG.TC file that you are using and rename or erase it. 3. Go to the BIN directory and rename or erase TCDEF*.* 4. If you are using a project file erase or rename .prj and .dsk. 5. Now run the IDE. 6. If you were using a project file re-create it. 7. Retry the operation that was previously giving you a problem. After preforming these steps you should have no memory corruption within the IDE environment until the first time a program is run from the IDE. This corruption is usually a result of a stray pointer in a user program that just happens to be pointing at the image of the IDE in memory. Until this pointer is caught and redirected the problem may persist. It is also possible for the image of the compiler to become corrupted even though the IDE is being run in protected mode because the image is stored in real memory and the CPU is running in real mode as your program executes from within BCX. If you have a particularly large project file you may wish to create a back up copy that you can use to replace a copy suspected of being corrupted. DISCLAIMER: You have the right to use this technical information subject to the terms of the No-Nonsense License Statement that you received with the Borland product to which this information pertains.