Refresh错误求助
#include <vcl.h>#pragma hdrstop
#include "Unit1.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TForm1::FormPaint(TObject *Sender)
{
int x,y,px,py;
Canvas->Pen->Color=clBlack;
Canvas->MoveTo(10,160);Canvas->LineTo(310,160);
Canvas->MoveTo(160,10);Canvas->LineTo(160,310);
Canvas->Pen->Color=clGreen;
x=-100;
y=x*x/100;
px=x+160;
py=-y+160;
Canvas->MoveTo(px,py);
for(x=-100;x<=100;x++)
{
y=x*x/100;
px=x+160;
py=-y+160;
Canvas->LineTo(px,py);
}
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button1Click(TObject *Sender)
{
Refresh();
}
//---------------------------------------------------------------------------
错误:[Linker Error] Unresolved external '__fastcall TForm1::FormClick(System::TObject *)' referenced from D:\PROGRAM FILES\CPP\10\UNIT1.OBJ