dzBdsLauncher

dzBdsLauncher tries to solve the problem of accidentally opening a Delphi project with the wrong Delphi version.

While .dproj files can be opened with newer Delphi versions than the one that created them, it does not work the other way round. So if you open a Delphi 10 .dproj file with e.g. Delphi 2007 all you will get is an error message. If you open a Delphi 2007 .dproj file with Delphi 10 it will automatically convert it to the new format used by that version and it will become unreadable by Delphi 2007.

dzBdsLauncher tries to solve this using the following methods:

  1. File name suffixes
    • project.2007.dproj starts Delphi 2007
    • project.2010.dproj starts Delphi 2010
    • project.xe.dproj starts Delphi XE
    • project.xe2.dproj starts Delphi XE2
    • project.xe8.dproj starts Delphi XE8
    • project.10.dproj starts Delphi 10
    • project.10-1.dproj starts Delphi 10.1
    • project.10-3.dproj starts Delphi 10.3

    This is the most reliable method.

  2. Reading the <ProductVersion> from the .dproj file
    Unfortunately these ProductVersions are not unique, so this won’t always work.
  3. Reading the <DllSuffix> entry from the .dproj file
    This entry only exists for DLLs and packages though.
  4. Reading the <Disabled_Package> entries from the .dproj and .bdsproj file.

dzBdsLauncher can also handle .bdsproj (Delphi 2005 and 2006) and .dof files (Delphi 6 and 7, older versions won’t work). For .dpr files it looks for a corresponding .dproj, .bdsproj or .dof file (in that order) and analyzes it to find the correct Delphi version.

And last but not least, dzBdsLauncher can handle .groupproj files. It does this by analyzing the first project found in the group. And if everything else fails, it checks the full filename of the .groupproj file for hints on the Delphi version, e.g. it will interpret names like UnitTestsGrp_BDS2009, UnitTestsGrp_D2009, UnitTestsGrp_Delphi2009 or UnitTestsGrp_RS2009.

The idea is to register dzBdsLauncher as the handler for .dpr, .dproj, .bdsproj, .dof and .groupproj files in Windows so your chance for opening the right Delphi version when double clicking such a file will much higher than normal.

The tool is released under the MPL on SourceForge. You can download the latest version there and the source code is also available.