在TREEVIEW的Change加入代码,
把一标识放到TREENODE.DATA
例:
PInfodata = ^TInfodata;
TInfodata = record
ID : Integer;
MC : String;
BM : String;
end;
//加载TreeView
Var
TCNode : TFcTreeNode;
InfoData : PInfodata;
Begin
New(InfoData);
InfoData.ID:=0;
TCNode:=TreeComboXZC.Items.AddObject(Nil,Msg1,InfoData);
TCNode.ImageIndex:=0 ;
TCNode.SelectedIndex:=1;
End;
//切换
代码自已加