Pytanie jest takie:
Chce stworzyc property dla arraya i nie wiem jak to zrobic? [glowa]
moja klasa wyglada +- tak
TSwiatla = class (TCustompanel)
private
fCzasySwiatel: array [0..3] of word;
protected
procedure TSwiatla.SetLightsTime (Index: Integer; Value: Word);
function TSwiatla.GetLightsTime(Index: Integer): Word;
public
published
property Green: Word index 0 read GetLightsTime write SetLightsTime;
property Orange: Word index 1 read GetLightsTime write SetLightsTime;
property Red: Word index 2 read GetLightsTime write SetLightsTime;
property OrangeRed: Word index 3 read GetLightsTime write SetLightsTime;
property CzasySwiatel [Index: Integer]: Word read* GetLightsTime write SetLightsTime;
end;
Blad wywala mi tam gdzie jest gwiazdka [???] [???] [???]
Jak ktos mi powie gdzie jest blad a najlepiej go poprawi bede bardzo wdzieczny. [hurra]
Procedura i funkcja na razie jedynie zapisuje wartosc i odczytuje wiec nie ma sensu pisac ich. ;-)