Link to home
Start Free TrialLog in
Avatar of aninec
aninec

asked on

ASP.NET w/ VB Pass data in textbox on page into Labels on another page

The user enters data into 6 textboxes and then clicks continue.  The data in the textboxes then pass to labels on another page.  I have done this with a gridview and hyperlinkfields - not sure how to do this with textboxes.

This is sensitive information so query string would nto be the best choice from what I have read.
Avatar of raterus
raterus
Flag of United States of America image

Any reason you wouldn't first save the data to the database, then on the label page, you load and display.
Avatar of aninec
aninec

ASKER

Yes - I dont want to save the data until the user has completed the second page.  I just want to pass this info into the second page so that user can refer back to it if needed.
ASKER CERTIFIED SOLUTION
Avatar of raterus
raterus
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of aninec

ASKER

What about using PreviousPage?  Is this secure?

If PreviousPage IsNot Nothing AndAlso PreviousPage.IsCrossPagePostBack Then
                        Dim text1 As Textbox = CType(PreviousPage.FindControl("txtLast"), TextBox)
                  
                  
                  If text IsNot Nothing Then
                PtName.Text = text.Text
            End If
        End If
I think that'll work, however, I've not had much experience with it.  In order to use that, your first page, is going to have to post to the second page.  This is much different than the default behavior of asp.net pages, and if you haven't already configured that, you might be better off using the Session.
Avatar of aninec

ASKER

With the Session..is this on the users machine only?  Meaning I could have 5 users accessing the same page at the same time - entering the same data.
Session is per-user, and it's stored on the server.