Hi everyone,
I am passing values from one web page to another.I am using the following code in the web page. The user clicks a tree view link in order to view this web page.
Public Class FileNumber
Inherits System.Web.UI.Page
Public sourcepage As Login
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
If Not Page.IsPostBack Then
sourcepage = CType(Context.Handler, Login)
lblUserRights3.Text = sourcepage.Property1
End If
LeftNav.BuildTree("Tasks", lblUserRights3.Text)
This works fine on the first page where i use this code ,however, I get a specified cast is not valid error when I try to use the code on other pages even though I have called server.tranfer in the sourcepage for these pages.
Thank you
a
I am passing values from one web page to another.I am using the following code in the web page. The user clicks a tree view link in order to view this web page.
Public Class FileNumber
Inherits System.Web.UI.Page
Public sourcepage As Login
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
If Not Page.IsPostBack Then
sourcepage = CType(Context.Handler, Login)
lblUserRights3.Text = sourcepage.Property1
End If
LeftNav.BuildTree("Tasks", lblUserRights3.Text)
This works fine on the first page where i use this code ,however, I get a specified cast is not valid error when I try to use the code on other pages even though I have called server.tranfer in the sourcepage for these pages.
Thank you
a