procedure TForm1.TreeView1Change(Sender: TObject; Node: TTreeNode);
const
  cBoolStr: array[Boolean] of string = ('False', 'True');
begin
  Caption := cBoolStr[Node.Expanded];
end;

解决方案 »

  1.   

    我是这样写的为什么提示出错呢?
     
    if mytreenode2.Expand = true then break;
      

  2.   

    我是这样写的为什么提示出错呢?
     
    if treeview.items[2].Expand = true then break
      

  3.   

    TteeView1.Node.Expanded
    你的提示是什么?
      

  4.   

    if mytreenode2.Expanded then break; //Expand -> Expanded
      

  5.   

    提示:
    [Error] Unit1.pas(559): Not enough actual parameters
      

  6.   

    if mytreenode2.Expanded then break; //Expand -> Expanded
    Expand 这是函数
    Expanded 这是属性
      

  7.   

    to ihihonline:
    该休息了,晚安
      

  8.   

    这回这明白了,
    谢谢 ihihonline
    谢谢 zswang一人给你们10分以表谢意