Page 1 of 1

DrawText in TAnnotationTool

Posted: Fri Apr 03, 2009 2:23 pm
by 9339885
Hi,

I'm trying to derive a new class TMyTextBox from TRectangleTool.

class TMyTextBox : public TRectangleTool
{
protected :

// void __fastcall DrawText(void)/* overload */;

public :

__fastcall TMyTextBox(Classes::TComponent* AOwner);

};

__fastcall TMyTextBox::TMyTextBox(Classes::TComponent* AOwner)
: TRectangleTool(Owner)
{

}


When I compile this, I get error msg
Link 32 Error : Unresolved external '__fastcall TeeTools::TAnnotationTool::DrawTextA()' referenced from UNIT1.OBJ

So I add the following in the header file

void __fastcall DrawText(void)/* overload */;


void __fastcall TMyTextBox::DrawText()
{
TAnnotationTool::DrawText();
}

I still get the Link error msg. What am I doing wrong here?

Thanks

-Bill