Answer Posted / venkat
//create datatable
datatable dt = new datatable();
//Create new dataset :
DataSet ds = new DataSet();
ds.table.add(dt);
//Store the dataset directly into view state
ViewState["dsn"]=ds.table[0];
//retrieve the dataset where it required
DataSet ds = (DataSet)ViewState["dsn"];
GridView1.DataSource = ds.Tables[0];
GridView1.DataBind();
| Is This Answer Correct ? | 1 Yes | 3 No |
Post New Answer View All Answers
What does asp in asp.net stand for?
Why mvc is better than asp.net? : Asp.Net MVC
How to make paging concepts in datagrid in ASP.NET?
Define caching.
Which object encapsulates state or data of a user?
where can i gather the materials for MCP certification
What is use of <% %> in asp.net?
How can you ensure a permanent cookie?
What are the new features added from ASP to ASP.NET?
What are navigation controls? How many navigation controls are there in ASP.NET 4.0?
We are using Jscriopt validations and at clint site javascript is not running that time validation would work? if yes then how it would behave?
How do u deploy your asp.net application?
What is windows active directory authentication?
What are session state modes?
Explain why it is useful to use mvc instead of webforms? : asp.net mvc