How to Auto Update the CheckState of the parent nodes When Child's Changed Programmingly?
问题 I am using Delphi XE3 with Virtual TreeView. I have enabled the toAutoTristateTracking option. WHen I try to change the check state of a node manually, then the affected node's checkstate will change as well. However, when I do the same thing programmingly, for example PNode^.CheckState := csMixedNormal; or PNode^.CheckState := csCheckedNormal; Only PNode check state will be changed. The affected nodes will not change their states. Why? 回答1: Don't access CheckState of a node directly. Use