S
Savas Ates
I want to change my controls in my class
I have the following code. All the code in my _default page class
How can i solve it ?
public class antu:_default
{
public void GetHolder()
{
if ( (string)this.Page.Session["refcode"]=="antu")
{
Control ANTUUST = this.LoadControl("Skin/ANTUUST.ascx");
Control ANTUALT = this.LoadControl("Skin/ANTUALT.ascx");
this.ANTUUSTHOLDER.Controls.Add (ANTUUST);
this.ANTUALTHOLDER.Controls.Add (ANTUALT);
}
}
}
antu AntuHolder =new antu ();
private void Page_Load(object sender, System.EventArgs e)
{
// REFCODE KONTROLU
////////////////////////////////
string refcode;
refcode=Request.QueryString["refcode"];
if ( refcode!=null && Session["refcode"]==null)
{
refcode=refcode.ToLower();
Session["refcode"]=refcode;
}
AntuHolder.GetHolder();
I have the following code. All the code in my _default page class
How can i solve it ?
public class antu:_default
{
public void GetHolder()
{
if ( (string)this.Page.Session["refcode"]=="antu")
{
Control ANTUUST = this.LoadControl("Skin/ANTUUST.ascx");
Control ANTUALT = this.LoadControl("Skin/ANTUALT.ascx");
this.ANTUUSTHOLDER.Controls.Add (ANTUUST);
this.ANTUALTHOLDER.Controls.Add (ANTUALT);
}
}
}
antu AntuHolder =new antu ();
private void Page_Load(object sender, System.EventArgs e)
{
// REFCODE KONTROLU
////////////////////////////////
string refcode;
refcode=Request.QueryString["refcode"];
if ( refcode!=null && Session["refcode"]==null)
{
refcode=refcode.ToLower();
Session["refcode"]=refcode;
}
AntuHolder.GetHolder();