1
votes

In a Delphi application, a visual component VC, inherited from TFrame, has been developed and added to the Components Palette APP_PALETTE via the Structure pane (Structure \ right-click \ Add to palette).

In one of the forms of the application, an instance of the mentioned component has been created by clicking the component on the palette APP_PALETTE and then clicking on the form.
In the IDE, the component is properly displayed inside the form.
The application compiles without errors or warnings.

However, at run time, when the form is loaded, the component is not displayed.

In addition, when the project is closed and reopened, the following dialog box is displayed:
Error reading form: [name of the form where component was created]
Class [class of component VC] not found. Ignore the error and continue? NOTE: Ignoring the error may cause components to be deleted or property values to be lost.

I have not developed the component nor the application, but I do have access to the source code. I was wondering if a path or some kind of configuration is missing...

Suggestions on how to solve the problem would be much appreciated.
Thank you in advance.

PTM

Here is my environment:
Embarcadero Delphi 2010 Version 14.0.3593.25826
Windows XP Professional Version 2002 Service Pack 3

1
Does your frame appear in the .dpr file?David Heffernan
Yes, the frame is listed in the dpr file, in the Uses clause.PTM

1 Answers

2
votes

This is weird way using a TFrame. The normal way is to use the Frame component in the palette and then select the type of frame to insert into the form from the list. No need to use Add to palette. A frame has to be part of the project to make this work.