| | |
direct mapping from treeview to datagridview
Please support our C# advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Oct 2008
Posts: 56
Reputation:
Solved Threads: 0
hi,
i am doing some windows application program using .net.
i show the information in treeview. when user selects the data from treeview. i like to show in datagrid view.
i do't know any direct mapping is present or not. if present please share ur ideas.
(now currently i m collect the tree node and add that information into datagridview.)
i am doing some windows application program using .net.
i show the information in treeview. when user selects the data from treeview. i like to show in datagrid view.
i do't know any direct mapping is present or not. if present please share ur ideas.
(now currently i m collect the tree node and add that information into datagridview.)
If you want to show detailed data on GridView based on master data on TreeView, say TreeView holds Car Models and you need when use selects Car Model from TreeView, its details shows in GridView.
You'd have DataSource which takes Car Model as a parameter, and assign GridView.DataSource to it, when user selects node send its name to the DataGrid DataSource to fill it.
You'd have DataSource which takes Car Model as a parameter, and assign GridView.DataSource to it, when user selects node send its name to the DataGrid DataSource to fill it.
BI Developer | LINKdotNET
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
Hi,
Use TreeView.AfterSelect event to fill the Grid, it gets fire when node has been selected. Here you can assign the data associated with selected node, to the GridView.
Use TreeView.AfterSelect event to fill the Grid, it gets fire when node has been selected. Here you can assign the data associated with selected node, to the GridView.
Freedom in the Mind, Faith in the words.. Pride in our Souls...
Indian Developer
http://falaque.wordpress.com/
Indian Developer
http://falaque.wordpress.com/
•
•
•
•
if possible give some syntax. its useful for my reference.
BI Developer | LINKdotNET
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
![]() |
Similar Threads
- Help with automatic update problem and more (Viruses, Spyware and other Nasties)
Other Threads in the C# Forum
- Previous Thread: Passing Variable to another form
- Next Thread: How I use IsMdiConteiner
Views: 1420 | Replies: 4
| Thread Tools | Search this Thread |
Tag cloud for C#
.net access ado.net algorithm array barchart bitmap box broadcast button buttons c# chat check checkbox class client combobox control conversion csharp custom database datagrid datagridview dataset datetime degrees development draganddrop drawing encryption enum event excel file files form format forms ftp function gdi+ httpwebrequest image index input install java label list listbox listener login mandelbrot math mouseclick mysql networking operator oracle path photoshop picturebox pixelinversion prime programming radians regex remote remoting resource richtextbox save saving serialization server socket sql statistics stream string table tcp text textbox thread time timer treeview update usercontrol validation view visualstudio webbrowser windows winforms wpf xml






