Click here to Skip to main content
15,885,782 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi all,

I'm fairly new to programming (been at it for a year now). I'm having some trouble with my program. I use a lot of datagridviews but somethimes it just doesn't cut it (or i don't know how to do it) :-)

My question to all you advanced programmers. I have a table called orders (sql 2008 database) with some fields like: OrderID, Date, OrderedBy,... And then i have another table called Orderlines with the fields as: OrderID, ProductID, Quantity, Amount, Cost, LineNR,...

These twoo relate one to many. So orders is the 'headline' and it has some detailed orderlines. Now i would like to show them in a grid of some sort that users can expand per orderID and so expand the orderlines. Is something like this possible? Any step in the right direction would be grately appreciated.

BTW: i used to have the orders in one grid and then with selection changed i showed the orderlines in another grid.

Thanks in advance (and sorry for my english)!

Greetings
Posted
Updated 9-Jul-12 9:52am
v2

1 solution

IF this problem is WPF related I would create a ListView that had one filed with an expander in it called Orders. In Windows Forms I dont really know...
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900