How to bind table coloum with gridview column
Answer Posted / eyesice
DataTable dt = new DataTable("Sample");
DataColumn dc;
dc = new DataColumn("ID");
dc.DataType = System.Type.GetType("System.Int32");
dt.Columns.Add(dc);
dc = new DataColumn("Name");
dc.DataType = System.Type.GetType("System.String");
dt.Columns.Add(dc);
dataGridView1.DataSource = dt;
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
what is linq to entities?
What is filters in web api?
how can you tell ef to have a different table or column name than that defined for the class?
How we can call a javascript function on the change of a dropdown list in mvc?
What is asp net framework?
Why to use “{resource}.axd/{*pathinfo}” in routing in mvc?
What are the advantages of razor view engine?
When using aspx view engine, to have a consistent look and feel, across all pages of the application, we can make use of asp.net master pages. What is asp.net master pages equivalent, when using razor views?
What is the benefit of entity framework?
How OS come to know whether to load the .net framework when we run an .exe created using .Net framework?
What is the greatest advantage of using asp.net mvc over asp.net webforms?
What is html.renderpartial?
explain lazy loading, eager loading, and explicit loading?
What is a view engine?
What is basic authentication in web api?