Passing information in DataTable from one WebForm to another... 
Author Message
 Passing information in DataTable from one WebForm to another...

Hi all!

I have a small problem... I am populating a DataTable on one webform and
then I want to be able to click on a hyperlink and open a new webform and
from that webform have access to the DataTable that I'm filling on my first
webform, can anyone give me a hint about how I can achieve this?

Can I pass the data in something like a querystring or can I make the
DataTable public in the first webform and access it that way, or?

Thanks in advance
Martin



Mon, 31 Jan 2005 00:02:45 GMT  
 Passing information in DataTable from one WebForm to another...

Quote:

> Hi all!

Hi Martin.

Quote:
> I have a small problem... I am populating a DataTable on one webform and
> then I want to be able to click on a hyperlink and open a new webform and
> from that webform have access to the DataTable that I'm filling on my first
> webform, can anyone give me a hint about how I can achieve this?

> Can I pass the data in something like a querystring or can I make the
> DataTable public in the first webform and access it that way, or?

I don't think you can pass it as a query string or make it public.

What's worked for me is declaring the table as a session variable i.e., in
your global.asax,

Dim mytbl as Datatable()

then you can access the table, for instance, in your first webform with,

Session("mytbl") = New Datatable()

and in the second webform with,

Session("mytbl").Rows.Add(myrow)

etc.

HTH.



Mon, 31 Jan 2005 00:28:36 GMT  
 Passing information in DataTable from one WebForm to another...
I was going to say the exact same thing.

Ryan Dawson


Quote:
> Hi all!

> I have a small problem... I am populating a DataTable on one webform and
> then I want to be able to click on a hyperlink and open a new webform and
> from that webform have access to the DataTable that I'm filling on my
first
> webform, can anyone give me a hint about how I can achieve this?

> Can I pass the data in something like a querystring or can I make the
> DataTable public in the first webform and access it that way, or?

> Thanks in advance
> Martin



Mon, 31 Jan 2005 01:03:32 GMT  
 Passing information in DataTable from one WebForm to another...
Thanks a lot, just what I needed...

/Martin


Quote:
> I was going to say the exact same thing.

> Ryan Dawson



> > Hi all!

> > I have a small problem... I am populating a DataTable on one webform and
> > then I want to be able to click on a hyperlink and open a new webform
and
> > from that webform have access to the DataTable that I'm filling on my
> first
> > webform, can anyone give me a hint about how I can achieve this?

> > Can I pass the data in something like a querystring or can I make the
> > DataTable public in the first webform and access it that way, or?

> > Thanks in advance
> > Martin



Mon, 31 Jan 2005 15:53:23 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Passing SQL statement from one webform to another

2. I cannot believe no one knows how to pass a dataset or datatable to Crystal

3. Call (open) one WebForm from another WebForm

4. Passing information from one database to other.

5. Passing Info Through Webforms

6. how to reference webform control from another webform???

7. Does any one know how to get more information from file

8. One Information Please

9. Passing information from VB Application to Visio

10. pass changed information for word back to vb

11. vba bookmarks passing information from vba to a document

12. vba bookmarks and passing information from vba to a document

 

 
Powered by phpBB® Forum Software