Hi,
How to show two or more table in a GridView?
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jignesh TrivediPosted Aug 20, 2012, 11:55 PM
there are many way to show data in grid view from two or more table..
you can also write combine query using join and union that return result that you want.
you can also create data relation between datatable.
please refer..
http://social.msdn.microsoft.com/Forums/en-US/adodotnetdataset/thread/f63f612f-20be-4bad-a91c-474396941800
http://msdn.microsoft.com/en-us/library/0k21zcyx%28v=vs.71%29.aspx
hope this will help you.
Akkiraju IvaturiPosted Aug 20, 2012, 4:51 PM
There are many ways to merge the data into one source. If you have multiple data sets, you can merge them into one using syntax dataset1.Merge(dataset2).
Otherwise, you can loop through the datatable's data rows and add the data into one of the datatables and bind the datatable data to the gridview.
Let me know what is your requirement with more details so that I may help you out with more accurate info.