主题:[讨论]动态创建的Tshape对象如何显示?错在哪里?
procedure TForm1.Button1Click(Sender: TObject);
var myshape:Tshape;
begin
myshape:=TShape.Create(form1);
myshape.Visible:=true;
myshape.Width:=200;
myshape.Height:=200;
myshape.Top:=150;
myshape.Brush.Color:=rgb(255,0,0);
//myshape.Show();
//myshape.Invalidate;
myshape.Refresh;
end;