My Project: Windows Form App written in C# VS2008
I am seeking some advice and possible example for the following dilemma. I am new to Linq To Sql and Linq To DataSet and I am trying to find the best straightforward way to fill a DataGridView by using a Linq query and possibly Stored Procedures later.
I have read various posts on using var and IEnumerable return datatypes and what I am simply trying to do to no avail is basically "Select * From TableName". My initial approach was to fill the DataGridView with a DataTable and I think I have learned that Linq To Sql will not return back a DataTable list from a query, only a list of Objects of type IEnumerable<Object>. My DB Table contains various datatype values for the fields (int, string etc). So, once we receive the list of IEnumerable objects, do we tuck a DataTable into a DataSet and then load the IEnumerable objects into the DataTable and the bind the DataGridView to a BindingSource control? I'm confused and lost, can someone help assist me?
Start Free Trial