G
Guoqi Zheng
Dear sir,
I have Page Header user control. On my main page, I have the following code.
<uc1:header id="MyHeader" runat="server"
PageName="OurProducts.aspx"></uc1:header>
PageName property is a public variable inside that user control. When I put
the value of PageName inside the html code, everything works ok. However, I
would like to determine the value of PageName by coding. So I do the
following.
public Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
MyHeader.PageName = "Others.aspx"
End Sub
When I tried to compile the code, I always get an error of Name "MyHeader"
not declared.
Can someone point out what I did wrong here? I am using VS.NET 2003
--
Met vriendelijke groet,
Guoqi Zheng
Tel: +31 (0) 23 5407422
Mob: 0648252520
http://www.meetholland.com
I have Page Header user control. On my main page, I have the following code.
<uc1:header id="MyHeader" runat="server"
PageName="OurProducts.aspx"></uc1:header>
PageName property is a public variable inside that user control. When I put
the value of PageName inside the html code, everything works ok. However, I
would like to determine the value of PageName by coding. So I do the
following.
public Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
MyHeader.PageName = "Others.aspx"
End Sub
When I tried to compile the code, I always get an error of Name "MyHeader"
not declared.
Can someone point out what I did wrong here? I am using VS.NET 2003
--
Met vriendelijke groet,
Guoqi Zheng
Tel: +31 (0) 23 5407422
Mob: 0648252520
http://www.meetholland.com