E
EdisonCPP
How can I call a function in one UserControl from another?
I have a custom sign in UserControl and another that needs
to display custom information based on the sign in along
the margin. I've been trying things I've found online, but
can't get a definition of the class.
// C#
private void Successful_SignIn()
{
//compile error: OtherControl is not defined
OtherControl control = (OtherControl)Page.FindControl("OtherControl1");
control.ShowCustomInformation();
}
These controls are on a MasterPage.
I have Session variables being setup in the sign in control, but apparently
the 2nd control's Page_Load() is going off before the sign in control.
Thanks,
Steven
I have a custom sign in UserControl and another that needs
to display custom information based on the sign in along
the margin. I've been trying things I've found online, but
can't get a definition of the class.
// C#
private void Successful_SignIn()
{
//compile error: OtherControl is not defined
OtherControl control = (OtherControl)Page.FindControl("OtherControl1");
control.ShowCustomInformation();
}
These controls are on a MasterPage.
I have Session variables being setup in the sign in control, but apparently
the 2nd control's Page_Load() is going off before the sign in control.
Thanks,
Steven