Search code examples
delphidelphi-2007

How can I stop forms from opening on Delphi IDE startup


For my first question ever on Stack Overflow I have to ask you about this issue I'm having with Delphi 2007.

At the startup of my project, the IDE always open a set of forms from my project.

For example, let's take a project where I have 50 forms. Every time I open the project, the IDE will open some of these forms (they are always the same one). My question being : Is there a list somewhere in the options where you can put a list of form to automatically open in Delphi on startup? I've been looking on 5 different forum about this and I've never found anything. Is this some sort of configuration?


Solution

  • Go to Tools->Options from the main menu.

    Check the Autosave options->Project desktop item, and click OK to apply the change. Close the dialog.

    Go back to your project. Close all the files you don't want to open any more when the project is first loaded, then use File->Save All from the main menu. (The quickest way to close the file is to right-click the editor tab at the top and choose Close Page from the context menu.)

    The IDE will remember the forms you have open when you save the project, and will reopen them the next time the project is loaded. To make sure they're only the ones you want, close all of the forms you don't want to be open before exiting.

    You can remove forms that are being auto-opened by simply making sure they're closed when you next save the project. (And conversely, you can add forms that you want to be auto-opened by just making sure they're open when the project is saved.)