Problem with Treeview
-
That worked but one more problem has raised, when I select other node the previous node is again changing to red color from green. What could be the solution... Also can you suggest me any refference for this SelectedImage property like how it works and so. Thanks:
Rakesh
-
Hi Ed, Can you help me solving one more problem? I want to retain the back color of the selected node when I change the selection of the node through my form's next/previous buttons. To be clear when I am clicking on any node with mouse the backcolor is turning to blue(system generated). But when I am changing the selection the backcolor of the newly selected node is turning to white. I tried to modify the backcolor explicitly but I am not getting the same color as if system is giving by default. thanks in advance, Rakesh. Rakesh
Rakesh
-
Hi Ed, Can you help me solving one more problem? I want to retain the back color of the selected node when I change the selection of the node through my form's next/previous buttons. To be clear when I am clicking on any node with mouse the backcolor is turning to blue(system generated). But when I am changing the selection the backcolor of the newly selected node is turning to white. I tried to modify the backcolor explicitly but I am not getting the same color as if system is giving by default. thanks in advance, Rakesh. Rakesh
Rakesh
-
-
Hi Ed, Can you help me solving one more problem? I want to retain the back color of the selected node when I change the selection of the node through my form's next/previous buttons. To be clear when I am clicking on any node with mouse the backcolor is turning to blue(system generated). But when I am changing the selection the backcolor of the newly selected node is turning to white. I tried to modify the backcolor explicitly but I am not getting the same color as if system is giving by default. thanks in advance, Rakesh. Rakesh
Rakesh
-
SystemColors.Highlight has solved my purpose. One more thing I am looking for is: I want to have some gap between each node of my tree. I have used indent property for this but there is no effect. Can you tell me way? Thanks in advance:
Rakesh
-
HI Ed, Now I want to implement the key down event. Means when user clicks on down arrow I want next item to be diplayed and other wise if Up arrow. For this I am using the tv_KeyDown event and changing the item on the arrow clicked either Up or Down. But the problem is for the first click it is moving two nodes istead of one. And from then working fine. Please let me know your thoughts on this. Thanks:
Rakesh
-
HI Ed, Now I want to implement the key down event. Means when user clicks on down arrow I want next item to be diplayed and other wise if Up arrow. For this I am using the tv_KeyDown event and changing the item on the arrow clicked either Up or Down. But the problem is for the first click it is moving two nodes istead of one. And from then working fine. Please let me know your thoughts on this. Thanks:
Rakesh
-
I am explicitly selecting the first node tv.SelectedNode = tv.Nodes[0]; and here is my code: private void tv_KeyDown(object sender, KeyEventArgs e) { if (e.KeyValue == 40) //code for down key only { if (currentItemCount > -1 ) { MyItem[currentItemCount].Visible = false; tv.Nodes[currentItemCount].BackColor = Color.White; currentItemCount+= 1; MyItem[currentItemCount].Visible = true; if (tv.SelectedNode != null) { tv.SelectedImageIndex = tv.Nodes[currentItemCount].ImageIndex; } } }
Rakesh