5,928
社区成员




unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls,Unit2;//Unit2为TFrame1;
type
TForm1 = class(TForm)
Panel1: TPanel;
Button1: TButton;
procedure FormCreate(Sender: TObject);
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
Frame1:TFrame1;
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.FormCreate(Sender: TObject);
begin
Frame1 := TFrame1.Create(self);
Frame1.Parent := Form1;
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
Frame1.CheckBox1.Enabled := false;
end;
end.