R
RAM
Hello,
I am learning .NET. I defined my own control:
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Header.ascx.cs"
Inherits="HeaderDoc" %>
<asp:TextBox ID="Year" runat="server" /><br />
....
and I used it on a second page:
<%@ Register TagPrefix="MIMStock" TagName="Header" Src="~/Header.ascx" %>
.... <MIMStock: ID="Header" runat="server" />
Now I would like to access elements of Header in code behind of the second
page:
Header.Year.Text = "..."
But it doesn't compile. How to do it?
Please help.
Thank you!
/RAM/
I am learning .NET. I defined my own control:
<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Header.ascx.cs"
Inherits="HeaderDoc" %>
<asp:TextBox ID="Year" runat="server" /><br />
....
and I used it on a second page:
<%@ Register TagPrefix="MIMStock" TagName="Header" Src="~/Header.ascx" %>
.... <MIMStock: ID="Header" runat="server" />
Now I would like to access elements of Header in code behind of the second
page:
Header.Year.Text = "..."
But it doesn't compile. How to do it?
Please help.
Thank you!
/RAM/