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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

TreeView Selection Problem

Thread ID:





33370 Aug 18,2005 01:19 PM UTC Aug 22,2005 04:18 PM UTC WinForms 6
Tags: Tools
Asked On August 18, 2005 01:19 PM UTC

I am using a TreeViewAdv. Here my requirement is to pupulate a TreeView when a button is clicked & the text on button should be the default selection in the treeview. I am able to do that but only problem I face is the way the node is selected. Here I use the following code to select the node TV.SelectedNode=node; TV.SelectedNode.BringIntoView(); where TV is my TreeViewAdv & node is TreeNodeAdv. Pls check the attached images to get a better Idea about my problem. Thanks Images_902.zip

Vijayanand S [Syncfusion]
Replied On August 18, 2005 02:36 PM UTC

Hi Vinay, You could use the following code for this purpose this.treeViewAdv1.Focus(); Please take look at this test sample and let me know if you have any questions. We appreciate your interest in Syncfusion products. Thanks, Vijay

Replied On August 18, 2005 03:12 PM UTC

Hi Vijay, Sample works fine, but when I try to put the same code in my application it doesnot work. when I try TV.SelectedNode=node; TV.SelectedNode.BringIntoView(); TV.Focus(); Console.WriteLine("Focus Value : " + TV.Focus()); Focus Value : False Also tried TV.SelectedNode=node; TV.Focus(); Console.WriteLine("Focus Value : " + TV.Focus()); Focus Value : False Can you tell me what could be the reason. Thanks for early response

Vijayanand S [Syncfusion]
Replied On August 18, 2005 03:35 PM UTC

Hi Vinay, I was unable to see that "false" value in my appllication and I could not predict what is that reason for your application. Could you please send me your sample otherwise modify my sample according to show that issue. Thanks, Vijay

Replied On August 18, 2005 03:52 PM UTC

Here my TreeViewAdv inside a Tabcontrol this is a user control & this particular User Control is called from a Windows Form. Could this be a reason.

Vijayanand S [Syncfusion]
Replied On August 19, 2005 09:40 AM UTC

Hi Vinay, I am afraid, I am not able to understand what you have done in your project. Could you please provide me more information? I have attached a modified sample according to your requirement. Please let me know if it helps. I would appreciate it, if you could create a test sample or modify the above sample and send it over to us. It will help us to investigate and give exact solution. If you wish to maintain the confidentiality of your sample, please create a Direct-Trac incident in this regard and mention the link to this forum post. Please let me know if you have any questions. Thanks for your patience. Regards Vijay

Replied On August 22, 2005 04:18 PM UTC

Hi Vijay, Thanks for the modified code. I tried some options and luckly one worked. Now my problem is solved. Thanks Vinay


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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