This is a migrated thread and some comments may be shown as answers.

Creating RadSkinManager from code-behind

2 Answers 71 Views
SkinManager
This is a migrated thread and some comments may be shown as answers.
Al
Top achievements
Rank 1
Iron
Iron
Iron
Al asked on 04 Dec 2014, 12:45 PM
Can someone please explain why this code does nothing on my page? 


public partial class SettingsDialog : System.Web.UI.Page
{
 
    public RadSkinManager rsm;
 
    protected void Page_Load(object sender, EventArgs e)
    {
        rsm = new RadSkinManager();
        rsm.Skin = "Glow";
        Form.Controls.Add(rsm);
         
    }
}

2 Answers, 1 is accepted

Sort by
0
Boyan Dimitrov
Telerik team
answered on 09 Dec 2014, 11:42 AM
Hello,

The Page_Load event handler is too late in order to add the skin manager to the page and apply the desired skin to the Telerik controls. Please use Page_Init instead as shown below:
//code
public RadSkinManager rsm;
 
    protected void Page_Init(object sender, EventArgs e)
    {
        rsm = new RadSkinManager();
        rsm.Skin = "Glow";
        rsm.Enabled = true;
        Form.Controls.Add(rsm);
 
    }



Regards,
Boyan Dimitrov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Al
Top achievements
Rank 1
Iron
Iron
Iron
answered on 09 Dec 2014, 11:48 AM
Thanks Boyan
Tags
SkinManager
Asked by
Al
Top achievements
Rank 1
Iron
Iron
Iron
Answers by
Boyan Dimitrov
Telerik team
Al
Top achievements
Rank 1
Iron
Iron
Iron
Share this question
or