C
Craig Kenisston
Is this possible ?
I have a code that does this :
if ((Request.IsAuthenticated == false))
{
LeftPane.Controls.Add(Page.LoadControl("~/_AccessControl.ascx"));
LeftPane.Visible = true;
}
This loads the accesscontrol usercontrol into a cell named "LeftPane".
But now I want to use the same approach to load an "*.aspx" page into
another cell.
The code tells me the error "User control source files must have a .ascx
file extension", so, the same method doesn't work with an aspx file, just
with controls.
How can I do a similar thing but with a page ?
if that not possible, I'll thank any other usefull advise on achieve similar
results.
Regards,
I have a code that does this :
if ((Request.IsAuthenticated == false))
{
LeftPane.Controls.Add(Page.LoadControl("~/_AccessControl.ascx"));
LeftPane.Visible = true;
}
This loads the accesscontrol usercontrol into a cell named "LeftPane".
But now I want to use the same approach to load an "*.aspx" page into
another cell.
The code tells me the error "User control source files must have a .ascx
file extension", so, the same method doesn't work with an aspx file, just
with controls.
How can I do a similar thing but with a page ?
if that not possible, I'll thank any other usefull advise on achieve similar
results.
Regards,