The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,343 other followers

Delphi – finding out the design-time package name of a unit

Posted by jpluimers on 2009/04/24

Somehow I keep forgetting this ‘be aware though’ part below, hence this blog post :-)

When you are developing packages, sometimes you need units that are part of the VCL/RTL source tree.
Normally when compiling such a package, Delphi suggests the depending VCL/RTL package to add to your required package list.
However, that does not always work, especially with design-time packages (those start with ‘dcl’ in stead of ‘vcl’).

The last time I bumped into this was when I developed a package that needed the MessageDigest_5 unit.

The easiest way to find out which package to add to the required package list, is to use ModelMaker ModelMaker Code Explorer, aka MMX: a great Delphi productivity tool well worth its price (only a mere EUR 99!).
MMX adds a Tools submenu (shown on the right), which has the “package classes report” option.
When you select that, you get a list of all classes and interfaces that are part of any loaded package:
So this is a quick way to find that the MessageDigest_5 unit is in the dclsoap100 package.

Another way to find out is to add the VCL/RTL unit you need to the package you are developing, then try to install that package.
Upon installing, you then get an error message like this (I was developing the MD5Package package):


Cannot load package 'MD5Package.' It contains unit 'MessageDigest_5,'which is also contained in package 'dclsoap100'

OK Details >>

This gets you the RTL/VCL package you need to add to your required packages list: dcpsoap100 .
Be aware though:
you must add required packages without a version number (because they change with each new Delphi version), so in stead of adding dclsoap100 you must add dclsoap to the required list of packages.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: