Thursday, August 30, 2007

Delphi IDE - Registry Root Switch

Didja-Know ... there is a command line switch built into the IDE that will allow you to switch the registry root that the IDE uses when loading. Yea, a completely different configuration from a short-cut you create that uses the "-r" command-line switch.

Someone mentioned it in a NG post recently and I thought it was pretty cool ... certainly worth keeping at hand but I went looking for it [to give credit to the author of the post] and came up empty.  I did manage to find a Sep 21, 2004 post by Allen Bauer [now Chief Scientist at CodeGear] that really explains it well:


One thing you can do with all versions of Delphi from at least D5, is use the "-r" command-line switch.  This allows you to specify the root registry key to use when loading the IDE.  For instance in D7, you could export the HKCU\Software\Borland\Delphi key to a file.  Then rename the "Delphi" key to something else, like "SafeMode".  Then re-import the exported key to recreate the HKCU\..\Delphi key.  Finally, when you run the Delphi32 application, just pass the "-rSafeMode" switch to use that key.

--
Allen Bauer
Delphi/C#Builder Principal Architect
Borland Software Corporation.


 This is something that would have come in handy when testing out the Keyboard Short-Cut articles I put together a few months ago ... it certainly would have saved me from making the mistakes I made due to high-jacked short-cut key strokes by 3rd party IDE tools.

I'm thinking of setting up a "BareBones" root and short-cut that has all third party tools and IDE enhancements removed. When I need to try and find conflicts it will make things a lot easier to load the IDE using that key and start adding tools/utilities until the problem occurs. Then just delete the "BareBones" key and re-load it from a saved-to-disk copy.

Lots to play with ... I'm off. Thanks for stopping by,
Dave

 

Updates:

  • Delphi [2007 Win32] will build you a new [pretty much] empty key if one doesn't exist.
    Click »Start »Run and type in "bds -rBareBones" without the quotes and Delphi will create the empty BareBones root for you as it starts ...
    how cool is that ?!?

2 comments:

  1. welcome to the wow power leveling cheap service site, buy wow power leveling cheap wow gold,wow gold,world of warcraft wow power leveling buy wow gold

    ReplyDelete
  2. Nice ..Thanks for sharing this Delphi updates and utilities. outsourcing services on Delphi

    ReplyDelete