move the dxTreeList rectangle or highlight to other node(10分)

  • 主题发起人 主题发起人 huzb
  • 开始时间 开始时间
H

huzb

Unregistered / Unconfirmed
GUEST, unregistred user!

Hi
I had read and try
<a href="http://www.devexpress.com/dxforum/view.asp?ArticleID=284">How to Focus a Row after a Certain Row is Edited</a>
That is OK.

But when I try do this with dxTreeList, it's fail.
I just change or add these lines:

void TFormAddress::FindNode()
{
...
Node->MakeVisible();
Node->Focused = true;
PostMessage( this->Handle, CM_FOCUSENODE, 0, (long)(dxTreeList1->FocusedNode));
}

void TFormAddress::CMFocuseNode(TMessage &amp;Message)
{
((TdxTreeListNode*)Message.LParam)->Focused = true;
//TForm::CMFocuseNode(Message);
}

The rectangle or highlight not show.

When I add
dxTreeList1->SetFocus();
before or after "POST...", the rectangle move to next node but highlight not move to next node.

And when I do a increment search in dxTreeList with a TEdit, I can't write
dxTreeList1->SetFocus();

How can I show the rectangle or highlight on match node?

Thanks.
 
It seems you use the MultiSelect feature. Please try to set the Selected
property of your node to true.
Here is the sample code:

Node->Selected = true;
 
接受答案了.
 
后退
顶部