Eric
Joined: 06 Oct 2005 Posts: 15 Location: Regensburg, Germany
|
Posted: Mon Dec 19, 2005 4:21 pm Post subject: BUG?: Row.Selected = true -> no clear of current selectio |
|
|
Hi,
I need to find a row a show it in my VirtualTree.
I have made my own find method depending of the objects in my Tree (I am using ObjectBinding) and then,
Code: | Row foundRow = MyFindRowByID(...);
foundRow.EnsureVisible(); |
then I need to mark this foundRow.
A simple solution is to mark it selected:
Code: | if (!foundRow.Selected)
{
foundRow.Tree.SelectedRows.Clear();
foundRow.Selected = true;} |
I have set the "AllowMultiSelect" property to false for that tree.
I should add the foundRow.Tree.SelectedRows.Clear(); to clear the selection.
I am wondering why?
According to me, you should add this line (selectedRows.Clear) in the set property Selected of row when AllowMultiSelect of the tree is false;
This this indeed the case when selecting a row with the mouse, why not programmatic?
How do you think? |
|