Hallo,
Zum einen solltest du besser TStrings als formalen Typ benutzen.
Und dann brauchen solche Published Objekt-Properties immer einen Setter:
Delphi-Quellcode:
TfdStringGrid = class(TStringGrid)
private
FTest1: TStrings;
procedure SetTest1(const Value: TStrings);
public
constructor Create (Sender: TComponent); override;
procedure Datenzeigen;
published
property Test1: TStrings read FTest1 write SetTest1;
end;
constructor TfdStringGrid.Create (Sender: TComponent);
begin
inherited;
FTest1 := TStringList.Create;
Datenzeigen;
end;
procedure TfdStringGrid.SetTest1(const Value: TStrings)
begin
if Assigned(Value) then
FTest1.Assign(Value);
end;
procedure TfdStringGrid.Datenzeigen;
begin
showmessage ('Test1: '+FTest1.Text);
end;
Gruß
Neutral General
Michael
"Programmers talk about software development on weekends, vacations, and over meals not because they lack imagination,
but because their imagination reveals worlds that others cannot see."