How can I pass Dataset from one page to another?
-
I am developing an application in which one page is having DataGrid. I am showing limited columns in that datagrid. I want to show the details of that particular row on the next page after clicking the particular row in the datagrid. I don't want to go again to query the database to show the details of the row. Please tell me the method to pass Dataset or Datarow from one page to other in ASP.NET Thanks, Sandy Sekhon
-
I am developing an application in which one page is having DataGrid. I am showing limited columns in that datagrid. I want to show the details of that particular row on the next page after clicking the particular row in the datagrid. I don't want to go again to query the database to show the details of the row. Please tell me the method to pass Dataset or Datarow from one page to other in ASP.NET Thanks, Sandy Sekhon
I have one idea better store that Datatable in the session as a table this may work :((
-
I am developing an application in which one page is having DataGrid. I am showing limited columns in that datagrid. I want to show the details of that particular row on the next page after clicking the particular row in the datagrid. I don't want to go again to query the database to show the details of the row. Please tell me the method to pass Dataset or Datarow from one page to other in ASP.NET Thanks, Sandy Sekhon
You could store the datatable(s) in a session item. An even better option is two put the grids on the same webpage and store the data in viewstate. You can always hide one of the grids if you need to with javascript or with server code. "People who never make mistakes, never do anything." My Blog
-
You could store the datatable(s) in a session item. An even better option is two put the grids on the same webpage and store the data in viewstate. You can always hide one of the grids if you need to with javascript or with server code. "People who never make mistakes, never do anything." My Blog
-
Well, the thing with session items like that is that they can get all screwed up if the use clicks the back and foward buttons. Also, they take up more resources. I haven't had any issues with storing a datatable in viewstate, but perhaps there are issues I don't know of. "People who never make mistakes, never do anything." My Blog
-
I am developing an application in which one page is having DataGrid. I am showing limited columns in that datagrid. I want to show the details of that particular row on the next page after clicking the particular row in the datagrid. I don't want to go again to query the database to show the details of the row. Please tell me the method to pass Dataset or Datarow from one page to other in ASP.NET Thanks, Sandy Sekhon
well you cant store a datatable within the session because it's not serializable. Oddly the DataSet is You can easily store it in the Session( DataSet ) and then retrieve at the next page. If its really small store in the viewstate. Otherwise keep it in the session. If you have problems of click back and forward you should implement the Momento design pattern 1 line of code equals many bugs. So don't write any!!
-
I am developing an application in which one page is having DataGrid. I am showing limited columns in that datagrid. I want to show the details of that particular row on the next page after clicking the particular row in the datagrid. I don't want to go again to query the database to show the details of the row. Please tell me the method to pass Dataset or Datarow from one page to other in ASP.NET Thanks, Sandy Sekhon
Hi, You can do this using session variables. After creating a dataset Session["dataset}]= dataset --------- while accessing DataSet ds = (DataSet)(Session["dataset"]); Thanks and Regards Gowtham Sen