Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Link Button
Message
 
À
14/08/2003 11:36:51
Mindy Shingara
Central Susquehanna Intermediate Unit
Lewisburg, Pennsylvanie, États-Unis
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Titre:
Divers
Thread ID:
00820167
Message ID:
00820386
Vues:
22
Mindy,

If I understand your issue correctly, there is actually a couple of simple resolutions for this issue. In your page_load on your main page, you could check for the existence of the session variables and then set the value of the controls to the session variable values if the session variables have been initialized.

In vb.net, it would look something like this.
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load


        If Not Session("variable1") Is Nothing Then
            Me.txtBox1.text = Session("variable1")
        End If

        If Not Session("variable2") Is Nothing Then
            Me.txtBox2.text = Session("variable2")
        End If

End Sub
regards,

JE

>Web Form: I have linkbuttons on my parent form to go to one of four child forms. I carry a few session variables to the child forms. On each child form, I am using another linkbutton to "Go Back to Main Page" which links back to my parent form. The IsPostBack property is false as I'm redirected to the parent form causing the form load() to fire again. I don't want the load() to fire because it resets all the controls. I want to carry the session variables, from the child form back to the parent form, to be displayed until the user clears the form. Please help! Hope this is clear enough.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform