(Gast)
n/a Beiträge
|
Re: Auf die Eigenschaften eines Forms zugreifen
13. Jan 2005, 13:22
Code:
SomeForm someForm = new SomeForm();
Code:
class MainForm :Form
SomeForm dialog;
public SomeForm Dialog
{
get{ return dialog;}
}
public MainForm()
{
dialog= new SomeForm();
}
}
Delphi-Quellcode:
var
SomeForm :TSomeForm;
begin
SomeForm = TSomeForm.Create();
Delphi-Quellcode:
type TMainForm = class(Form)
private fDialog :TSomeForm;
published property Dialog :TSomeForm read fDialog;
public constructor Create()
end;
implementation
constructor TMainForm.Create()
begin
fDialog := TSomeForm,Create();
end;
|
|
Zitat
|