Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2004.05.30;
Скачать: CL | DM;

Вниз

dxInspector из ExpressInspector Suite   Найти похожие ветки 

 
Sour   (2004-05-20 12:05) [0]

Как динамически создавать категории и итемы для dxInspector. Может у кого-нибудь есть примеры динамической работы с  dxInspector


 
Silver Alex ©   (2004-05-20 12:16) [1]

рабочий пример, думаю разберешься.Если нет, пиши, поможем

procedure TfrmIncome.CarVisible;
var
 aRow: TdxInspectorDBRow;
 aNode: TdxInspectorRowNode;
 n: Integer;
 
 function IsAssign: Boolean;
 var
  i: Integer;
 begin
   Result:=false;
   for i:=0 to  Inspector.Count-1 do
    if ((Inspector.Items[i] as TdxInspectorRowNode).Row  as TdxInspectorDBRow).FieldName="car" then
      Result:= true;
 end;
 
begin
 if (cdsIncome.FieldByName("mtid").AsInteger=UISMatType[mtFuel]) and not IsAssign and not (cdsIncome.FieldByname("cardid").IsNull) then
 begin
   aNode:=Inspector.AddEx(TdxInspectorDBRow);
   aRow:=aNode.Row as  TdxInspectorDBRow ;
   aRow.Caption:="Автомобіль";
   aRow.FieldName:="car";
 end
 else if (cdsIncome.FieldByName("mtid").AsInteger<>UISMatType[mtFuel]) or ((cdsIncome.FieldByName("mtid").AsInteger=UISMatType[mtFuel]) and (cdsIncome.FieldByname("cardid").IsNull)) then
 begin
   for n:=0 to  Inspector.Count-1 do
    if ((Inspector.Items[n] as TdxInspectorRowNode).Row  as TdxInspectorDBRow).FieldName="car" then
      Inspector.Items[n].Free;
 end;
end;


 
Sour   (2004-05-20 15:38) [2]

Спасибо на этом этапе разобрался



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

Текущий архив: 2004.05.30;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.026 c
4-1082300345
Privet10
2004-04-18 18:59
2004.05.30
Как управлять PGP


1-1084794449
inic
2004-05-17 15:47
2004.05.30
Threadы и т.п.


14-1083828393
Slava
2004-05-06 11:26
2004.05.30
Регламент резервного копирования


9-1075380883
Black Fury
2004-01-29 15:54
2004.05.30
Проблема с вызовом процедуры из *.dll


14-1084350738
xman
2004-05-12 12:32
2004.05.30
Install Shield EXPRESS