Вниз
Скачать: CL | DM;

Указатели   Найти похожие ветки 

← →
webpauk   (2005-03-04 19:01) [0]

Есть fArray array of tcontrols;

Tcontrol - любой объект
как сделать указатель Items на farray, чтобы в нем показывались только (Tcontrol as TmainMenu), например


← →
clickmaker ©   (2005-03-04 19:06) [1]


> webpauk   (04.03.05 19:01)

у массивов нет встроенных механизмов фильтрации. Руками


← →
Defunct ©   (2005-03-04 19:11) [2]

TControlList = class(TControl)
private
  fControls : Array of TControl;
 
  procedure SetItem(const Index: integer; AControl: TControl);
  function  GetItem(const Index: integer);

public
  property Items[Index : integer]:TControl read GetItem write SetItem;
 
end;

var
 Controls : TControlList;

begin
  Controls := TControlList.Create;
  ...

Вот, и в функции GetItem выбирать только те Control"ы которые (is TMainMenu)



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.45 MB
Время: 0.025 c
14-1109398331
31512
2005-02-26 09:12
2005.03.20
Распространённость различных операционных систем


1-1109764611
All
2005-03-02 14:56
2005.03.20
Delphi и Dll от FoxPro


1-1110003011
Эли
2005-03-05 09:10
2005.03.20
проблемы с модальной формой


3-1108832160
yyy
2005-02-19 19:56
2005.03.20
Выборка данных из базы


3-1108568740
juice
2005-02-16 18:45
2005.03.20
CREATE TABLE в хранимой процедуре




   Наверх