How to write Delphi Wizards
by Bob Swart (aka Dr Bob)
Delphi and C++Builder are truly open development environments, in that they have interfaces to enable us to integrate our own tools and experts within their IDE. This article will focus on writing and integrating Wizards (previously called Experts) with Delphi. The resulting (32-bits) Wizards will be compatible with Delphi 2.0x, Delphi 3 and C++Builder. Delphi has four kinds of Wizards: Project Experts, Form Experts, Standard Experts and (32-bits only) AddIn Experts. The first two can be found in the Repository, Standard Experts can be found under the Help menu (like the Database Form Expert), while AddIn Experts have to provide their own menu-interface with the Delphi IDE (typically anywhere in the menu except for the Help Menu, which seems to be reserved for Standard Experts only).
Project and Form Experts can be activated whenever you create a new Project or Form (just like Project and Form Templates).
Standard and AddIn Experts are the other kind of Wizards that generally do not create a new project or form, but provide some kind of information, or only create a new file or unit.
If you've ever tried an Wizard, you know what power and ease they can bring to you.
The Project Expert develops an entire project for you based on your specific preferences (like for example the Application Wizard).
The Form Experts develop custom forms that are added to your current project.
The Database Form Expert, for example, generates a form that displays data from an external database.
These example Wizards are not just external tools that can be started from Delphi, they actually communicate with Delphi and are an integrated part of the development environment.
While this is not so strange for the existing Delphi Experts (after all, they were developed and added by the same team that developed Delphi in the first place, and we all know Delphi's IDE is written in Delphi), it sounds intriguing at least to know that we, too, can write a Delphi Wizard that is able to communicate with Delphi in the same way.
Could we actually write an Wizard that also opens files in the IDE, that can be used to start a new project from scratch?
Yes, all this is possible, and more, as we will see shortly!
Standard Expert: TSysInfoExpert
Standard Expert: TFileOpenDialogExpert
Form Expert: TSplashFormExpert
AddIn Expert: TAddInMenuListExpert
AddIn Expert: TCompilerOutputExpert
(Editor's Note : Check for updated versions of this article on Dr Bob's Site.