0

I created a dynamic table in VB.NET on asp.net page and its shows right . But when I try to read the table on a click even I wrote: tablename.rows.count it shows 0 , in me page i see the table and the rows .

Image 1 Image 2

2
  • Are you sure Rachel is C#? I can see VB.NET in the code I edited your question. Commented May 21, 2018 at 9:03
  • is this row in created using JS? Commented May 21, 2018 at 9:12

1 Answer 1

0

How do you persist the table between pages? You state that you created a "dynamic" table which suggest that it isn't stored on disk or in a database somewhere. The quick way to deal with this is to store it in the Session object like so:

Session("MyDataTable") = MyDataTable

In the click event you retreive the datatable like so:

MyDataTable = Session("MyDataTable") 

using the basic session object requires that the client have session cookies turned on, there are other ways to deal with session (and persisting data), but this is the quick and dirty way.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.