
18.09.2011, 12:04
|
 |
Let Me Show You
|
|
Регистрация: 30.04.2010
Адрес: Северодвинск
Сообщения: 5,426
Версия Delphi: 7, XE5
Репутация: 59586
|
|
у меня все получилось:
Код:
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;
type
TMyForm = class(TForm)
public
function GetLabel: TLabel; virtual; abstract;
end;
TForm1 = class(TMyForm)
Label1: TLabel;
procedure FormCreate(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
function GetLabel: TLabel; override;
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TheLost(MyForm: TMyForm);
begin
MyForm.GetLabel.Caption:='TheLost';
end;
function TForm1.GetLabel: TLabel;
begin
Result:=Label1;
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
TheLost(Self);
end;
end.
__________________
Пишу программы за еду.
__________________
|