Solved

"Invalid class reference" error executing control panel applet

Posted on 2004-09-25
2
753 Views
Last Modified: 2010-04-16
Started a Control Panel Application in Delphi 7, setting icon, title and description. Created a Form window and set unit1(applet module) to use unit2 (Form). Runs the following code on applet activation:

with TForm2.Create(nil) do
try
  ShowModal
finally
  Free
end;

Installed the applet and launched Control Panel which produces 3 identical application errors:

Exception EAppletException in module Project1.cpl at 00022DD2.
Invalid class reference for TAppletApplication.

Double-clicking the applet icon from control panel produces the error once more before displaying form2 successfully. I don't think I'm trying to do anything special here, so hopefully I am missing something really obvious!

Thanks, J.
0
Comment
Question by:seizures
2 Comments
 
LVL 6

Accepted Solution

by:
vadim_ti earned 250 total points
ID: 12152318
Your Form2 is autocreated in your Project file (DPR)
delete or comment  string

 Application.CreateForm(TForm2, Form2);

in your .DPR file
0
 

Author Comment

by:seizures
ID: 12153948
That did the trick. It was driving me mad so thank you very much.
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

Suggested Solutions

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
This video discusses moving either the default database or any database to a new volume.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now