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

Code

3 Answers 28 Views
SkinManager
This is a migrated thread and some comments may be shown as answers.
Fred
Top achievements
Rank 1
Fred asked on 10 Oct 2014, 05:15 PM
Do you have sample code to do the skin change and display the color sample like in this screen shot?

3 Answers, 1 is accepted

Sort by
0
Galin
Telerik team
answered on 15 Oct 2014, 02:57 PM
Hi Fred,

Actually this is RadRotator, but the RadSkinManager is used to change the skin on item click.

<telerik:RadRotator ID="QsfSkinRotator" runat="server" FrameDuration="3000" AutoPostBack="true"
    RotatorType="Buttons" Height="87px" ItemHeight="87px" Width="100%" ItemWidth="105px"
    OnItemClick="QsfSkinRotator_OnItemClick" Skin="Default" WrapFrames="false" EnableDragScrolling="true"
    Style="margin-left: 0;"
    EnableEmbeddedSkins="false" EnableEmbeddedBaseStylesheet="false">
    <ItemTemplate>
        <a href="#" title="" class="qsf-rotator-link"><span class="qsf-rotator-thumbs qsf-rotator-<%# Container.DataItem %>"> </span>
            <asp:Label ID="SkinName" runat="server" CssClass="qsf-rotator-skin" Text="<%# Container.DataItem %>" />
        </a>
    </ItemTemplate>
    <ControlButtons LeftButtonID="leftArrow" RightButtonID="rightArrow" />
</telerik:RadRotator>

Code Behind:

protected void QsfSkinRotator_OnItemClick(object sender, RadRotatorEventArgs e) {
    var selectedSkinName = (e.Item.FindControl("SkinName") as Label).Text;
    QsfSkinManager.Skin = selectedSkinName;  //Set the skin on RadSkinManager
}


Please note this code is part of the examples, which I hope you have installed already.

I hope this helps.

Regards,
Galin
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
Fred
Top achievements
Rank 1
answered on 15 Oct 2014, 03:38 PM
where do I find these examples? I looked at demo code but this routine was not there.
0
Galin
Telerik team
answered on 20 Oct 2014, 03:29 PM
Hello Fred,

The provided code-snippet is part of the files:
Installation Folder\Telerik.Web.Examples\Common\UserControls\SkinChooser.ascx
Installation Folder\Telerik.Web.Examples\Common\UserControls\SkinChooser.ascx.cs

I hope this helps.

Regards,
Galin
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.

 
Tags
SkinManager
Asked by
Fred
Top achievements
Rank 1
Answers by
Galin
Telerik team
Fred
Top achievements
Rank 1
Share this question
or