We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Unable to scroll MultiColumnTreeView programmatically

Thread ID:

Created:

Updated:

Platform:

Replies:

98150 Feb 9,2011 02:43 PM UTC Feb 18,2011 06:58 PM UTC Windows Forms 1
loading
Tags: Tools
Philip Heroux
Asked On February 9, 2011 02:43 PM UTC

I do not seem to be able to scroll the control via code. Nothing I have tried works thus far works. If anyone could help shed some light on this matter I would be very grateful. I have provided the method which is supposed to scroll the tree into view below:

[Code]
private void ChangeTreeNodeAppearance(TreeNodeAdv node, Color foregroundColour, ImageIndex index)
{
if (m_EditorWndTreeView.InvokeRequired)
{
Invoke(new ChangeTreeNodeAppearanceDelegate(ChangeTreeNodeAppearance), new object[] { node, foregroundColour, index });
}
else
{
if (!node.IsVisible)
{
node.BringIntoView(); // Does not work
m_EditorWndTreeView.EnsureVisible(node); // Does not work
m_EditorWndTreeView.EnsureVisibleV(node, false); // Does not work

// This did not work
if (node.Parent != null)
{
m_EditorWndTreeView.Nodes[node.Parent.Index].Nodes[node.Index].BringIntoView();
m_EditorWndTreeView.Refresh();
}
else
{
m_EditorWndTreeView.Nodes[node.Index].BringIntoView();
}

// This did not work either.
m_EditorWndTreeView.SelectedNode = node;
m_EditorWndTreeView.SelectedNode.BringIntoView();
}

node.TextColor = foregroundColour;
node.SubItems[(int)MultiSelectTreeView.ColumnIndecies.BuildStatus].LeftImage = index == ImageIndex.Nothing ? null : m_ImageList.Images[(int)index];
m_EditorWndTreeView.Refresh();
}
}
[/Code]


Vallarasu S [Syncfusion]
Replied On February 18, 2011 06:58 PM UTC

Hi Philip ,

Thanks for your interest in Syncfusion products.

The methods you have specified works [BringIntoView,EnsureVisible] fine here, I have attached the sample used to test the behavior with this thread.

Please ensure this on your end and let me know the details on your product version if this fails.

Regards
Vallarasu S.




MCTree_11c3b9eb.zip

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;