treeview

how to select treeviewitem in wpf

hi everyone! i am new in wpf so forgive me i want more!!! i am trying to build an application. i have a treeview that bounded a datasource. it is okay. i have two problems. First; how can i select an item from treeview? i wanna a new window popsup when i select an item; when i click another item; another window popsup. Second problem i...

TreeView with custom drawn TreeNode

Hi I am trying to add a custom icon near the text of a TreeNode, so the items could have a "checked/unchecked" state displayed. I don't want to use a checkbox for that. Any ideas? Thanks ...

How to keep an area a constant/relative size while user expands/collapses treeview?

I have a window that will be a variable size, currently it is 300 x 400 as shown below. In the top part I have an expandable tree view In the bottom part I have a long horizontal panel with a button in it. I want the top area (treeview) to be about 95% of the height, with the button tool area a constant 50 high. I want these proportio...

How to change the color/opacity of the triangular icon on a TreeViewItem?

Some of my TreeViewItems are clickable and some are not. For those that are not clickable, I changed the Foreground color to gray. However, if that item has children, I want to also change the little triangular bullet to gray. How can I do that, something like this: //PSEUDO-CODE: <TreeViewItem IconBulletEnabled="False" IconBulletCo...

Treeview Nested in a GridView

Hi, I have dynamically added a TreeView to a cell in a GridView Control. The problem is the initial entry in the first node of the TreeView can be quite long. When the page is rendered the TreeView ends up increasing the size of my GridView column width because the first node does not wrap to the next line. When I view the source HTML ...

Delphi, VirtualStringTree - rebuilding tree, restoring state (expanded nodes)

How can I restore state of nodes in VirtualStringTree (which ones were expanded) at tree rebuilding? my application uses VirtualStringTree (one of the best components EVER!). Now, what I need is to rebuild the tree each time the application is started. In most cases however the "new" tree is the same as the one built last time... or at ...

ControlTemplate for second level of TreeView

I'm trying to create a TreeView which has two levels but I'm getting nowhere. I have an ItemTemplateSelector (which works - selecting either of the first two templates listed below), but I can't get the children to populate using a DataTemplate. This is my code: public class PlannedMealGroup : INotifyPropertyChanged { public Obs...

TreeView items disappear

I have a TreeView that is generated in code, and will look like this in the end: <TreeView> <TreeViewItem Header="X"> <TreeViewItem Header="Y"> <TreeViewItem Header="Z"> <StackPanel Orientation="Horizontal"> <TextBlock Width="100" Text="SomeText" /><TextBox Width="100" Text="TextInBox" /> </StackPan...

JFace TreeViewer flickering

I'm trying to update the input of JFace TreeViwer periodically using setInput() method. Also I use the viewer.setExpandedElements(expandedElements); viewer.setExpandedTreePaths(expandedTreePaths); methods to save the state of the tree. But after each setInput() call the TreeViewer flickers. How can avoid from flickering ? ...

.Net TreeView control - storing the data on the client side

I will have a TreeView control where the user can add/delete nodes, then click the Save button, which will save the data entered into the database. Normally, I would be saving the TreeView data inside session object while the user is editing it, but the way our web servers work, the session can not be relied on (I have been told NOT to ...

Reordering Treenodes in C#.NET

Hi, I have a Visual Studio 2005 C#.NET GUI application. I want to provide the flexibility to reorder the treenodes in the treeview just by dragging and dropping them wherever desired. Is that possible by using any property of the treeview class? Or do I have to do it the hard way by writing events for mouseup and then sensing the draggi...

Lines between nodes in WPF TreeView

All I want to know is if there's an easy way to add lines that connect nodes in a WPF TreeView, in the same manner as Visual Studio 2008's Solution Explorer pane. I found one solution but there's a lot of code and I want a simpler way. A thread on Microsoft's Silverlight forums seems to suggest that the lack of a "lines" option is due to...

TreeView bound to XMLDataProvider - shows data in editor, but empty when run

I have bound a TreeView to an XMLDataProvider. The TreeView displays the data as expected in the Visual Studio editor. But when I press F5, the application runs but the treeview is blank. Does anyone know why I can't see it when I run the application? Here's the entire code: <Window x:Class="TreeViewDataBinding.Window1" xmlns="htt...

treeview checked nodes

I have used the treeview control in my C# windows application. In that i have a few parent nodes and there child nodes. i have set the ShowCheckboxes properties as ALL. So if the ckeck box of a parent node or child node is checked how can i get the no. of checked nodes.In the foreach loop what code should i use? Please help me. ...

How can I access to system icons like "folder", "file" etc.?

Hi, I would like to use standard icons in treeview but I am not sure where to get them? I tried different places like resources etc., but without luck. thank you ...

Windows Forms .NET 3.5 using resource images for a Treeview control

Hello SO, When populating my treeview I would like to use the same images that I use in my toolbar etc which are stored in a resource file. The treeview seems to on accept images via an image list. I was thinking of reflecting and adding the resources to an image list on load... How do you guyz n girlz generally do this? ...

asp.net tree css adapter selectedNode is null?

I just switched to using the CSS Adapters for my TreeView control on one my ASPX pages. Now, for some reason, I cannot use the SelectedNode method except in my OnClick() event. ALL other events show that the SelectedNode is NULL. I am currently using a bunch of non-visible labels to store tree info everytime someone clicks on a node. ...

ASP.Net - Tree view control

I am using visual basic for coding. I drag & dropped a tree view control and edited its nodes. Now when I run my page I get this error-> Control 'TreeView1' of type 'TreeView' must be placed inside a form tag with runat=server. In the source I have the following entry asp:TreeView ID="TreeView1" runat="server" Height="155px" Style="z...

Making the silverlight TreeView control less bulky?

Hi, I'm very new to Silverlight. I've downloaded VS 2010 so that I can mess around with silverlight in a more graphical way and without having to pay a ton of money for Expression Blend 3.. So please have mercy if this is an obvious question. By default, in a tree view, all of the nodes are collapsed. I can get these to expand, but I wa...

In WinForms .NET C#, how to save to disk the state of a TreeView control

Hello, For a .NET 3.5 VS2008 treeview control, where the item labels are set to be editable, how do I save the changes to disk so that I can load them up again when the application restarts? Thanks ...