Add DataTable to ViewState

  • Thread starter Thread starter Kiran
  • Start date Start date
K

Kiran

Hi,

Can Someone tell me how to add a DataTable to ViewState.

Thanks
Kiran
 
I am surprised Kevin didn't answer this question.

DataTable table = new DataTable( "myTable" );

ViewState[table.ID] = table;

Are you having a specific problem storing it? One word of caution, if you
are storing a large amount of rows and columns, ViewState might not be the
best storage medium for you. The ViewState quickly becomes prohibitively
large.

bill
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top