|Home » Technical Support » Elevate Web Builder Technical Support » Support Forums » Elevate Web Builder Components » View Thread|
|Messages 1 to 4 of 4 total|
|Adding an Icon to a control|
|Wed, Aug 9 2017 9:05 AM||Permanent Link|
I created a custom control derived from TControl with a base- and a
caption-element. It's called "TCaptionPanel" and just looks like a
BasicPanel with a centered caption.
Now I tried to add an icon to the control and had a look at the TButton
control to study how it's done.
When compiling the changes I get this error:
"[Error] CaptionPanel.wbs (136,13): Cannot create an instance of the
class TCaptionPanelIcon when it contains abstract methods"
FIcon := TCaptionPanelIcon.Create(Self); <------------- Error here
InterfaceState := NORMAL_STATE_NAME;
FCaption := 'Caption';
The complete code is attached.
What am I doing wrong?
Attachments: CaptionPanel.wbs TCaptionPanel.wbi
|Thu, Aug 10 2017 1:16 AM||Permanent Link|
Uli Becker wrote:
// When compiling the changes I get this error:
// "[Error] CaptionPanel.wbs (136,13): Cannot create an instance of the
// class TCaptionPanelIcon when it contains abstract methods"
There's an abstract method
function GetFontIconElement: TElement; virtual; abstract;
in TIconProperties you did not override.
|Thu, Aug 10 2017 4:26 AM||Permanent Link|
> function GetFontIconElement: TElement; virtual; abstract;
> in TIconProperties you did not override.
Yes, I missed that. Thanks very much.
If someone is interested there are some more problems with the attached
code - once these are fixed, I'll post the component here again.
|Thu, Aug 10 2017 2:36 PM||Permanent Link|
Tim Young [Elevate Software]
Elevate Software, Inc.
I'm working with Uli on this, almost there...