473,698 Members | 2,261 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Check subnodes of treeview(with checkbox) clicking parent node

6 New Member
In my C# web application i have a treeview control with showcheckboxes = All . So for each node the check box is shown.


When i check on the parent node all its child nodes should be checked automatically. similarlly when i uncheck a parent node all its childnodes should be unckecked.

How can i do this?
Feb 12 '08 #1
0 1161

Sign in to post your reply or Sign up for a free account.

Similar topics

0
1516
by: Michael A. Covington | last post by:
Often we need to make a TreeView with checkboxes that have more than 2 states. Consider for example the TreeView of files and folders in a tape backup program. If the subordinate nodes of a particular node are partly checked and partly unchecked, then the node itself has a gray checkmark. I've hit on a way to do this with pure .NET functions, without using Win32 HitTest. See: ...
1
10756
by: JustinG | last post by:
I am relativley new to C#, and I am trying to write code using the compact framework, that will allow a handheld user to hit enter while a treeview node is selected, which will then do something based on that nodes text. I cannot figure out how to write a method for this event for a single node. When I double click on the treeview in design mode, the only function it creates (no matter where I click) is private void treeView1_AfterSelect(...)....
0
1662
by: Devhead | last post by:
I changed the treeview node text to bold and changed color "successfully". However, the node text was truncated and when i did a tree refresh the node formatting was gone. What do i need to do to 1) display the node text properly after i alter font style and color and 2) keep the node format change if user refreshes tree. i've been looking at the node.bounds property to increase the rectangle that the text is displayed in but what do i...
4
4622
by: Yavuz Bogazci | last post by:
Hi, i have created a treeview and this works nice. I have now a problem: I want to store 2 more Information to each Treeview Node like UserID and CompanyID. How can i do that? Thanks Yavuz Bogazci
8
14273
by: Don Wash | last post by:
Hi There! I'm using VB.NET to create a TreeView application and unfortunately I could not find "Key" property in Node items of the TreeView. We used to have "Key" property in TreeView node object in VB6. What is the equivalent of "Key" property of TreeView node in VB.NET? Has the property name "Key" has been changed to something else? Or VB.NET does not support the "Key" property anymore? If so what are the alternatives?
1
1826
by: ShadowFil | last post by:
Hello, In a MDI application, I want a child form which contains a treeview with a associated form for each node. If I create a child form, I only can put controls. So I can puta Treeview control and a user control which represents the form for one node. So I have the same count of user control than the count of nodes in the treeview. But I will prefer to have forms, and not user control which play the role of
0
1148
by: Christian Rühl | last post by:
Good Morning, I have generated a TreeView from a DOM. Now I want to set the checkboxes according to an ini file I've written. The ini file looks like this: .... Dsr=1 version=1 customer_control=0
3
21857
by: Michael_Burgess | last post by:
Hi there, I've looked around the different groups and still can't figure this out without resorting to scrappy code............ I want to programtically select and highlight a TreeView node, such that it looks the same as if a user has clicked it. I'm aware about the SelectedNode property, but this just seems to expand the TreeView to show the node in question, but not highlight
3
1719
by: bg_ie | last post by:
Hi, Lets say I have a TreeView with nodes that represent objects of a number of different types. Is there a way of associating the Set method of each object with its node in the TreeView? That way when you select a node in order to change its associated data, you have easy access to its Set function. The way I normally handel this situation is is to create an enum of all the different types that the treeview contains. I then have a
1
5106
by: R.A.F. | last post by:
Hi, I would like simulate a mouse click on on of my treeview nodes when my form opens. for that i was thinking to use the same simple way as under C++ : SendMessage(TreeView.Nodes.Handle, WM_LBUTTONDOWN,0,0); but it does not work. i do not get any error message and application runs normally... just my first node is not selected (clicked).
0
8609
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9169
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9030
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8871
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7738
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4371
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4622
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3052
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2335
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.