c# - Telerik Rad Customized Theme using RadSkinManager -
i need create theme using telerik rad controls new client. there 2 ways can it.
in existing application have few in-build telerik themes , populated using radskinmanager shown below. how can keep themes in radskinmanager drop down , add new customized theme client looking for?
<telerik:radskinmanager id="radskinmanager" runat="server" showchooser="true" visible="false" persistencemode="session"> </telerik:radskinmanager>
in order able list custom theme along side telerik themes required follow below steps.
- build custom theme using 1 of options listed under creating custom skin. made use of visual style builder tool create theme named
metrored
based on existing telerik theme , downloaded theme files. - build custom skin
dll
skin assembly builder using custom theme files per steps outlined in create custom skin dll existing custom skin skin's assembly builder - in asp.net project add reference custom skin dll created in step 2 above
- modify
radskinmanager
declaration below
e.g. default.aspx
skinchooser
drop down displayed.
<telerik:radskinmanager id="radskinmanager" runat="server" showchooser="true"> <skins> <telerik:skinreference assembly="metrored" /> </skins> </telerik:radskinmanager>
- displaying custom skin in
skinchooser
- add new skin explicitly indefault.aspx
page'sinit
(code behind) below:
e.g. default.aspx.cs
protected void page_init(object sender, eventargs e) { var skincombo = radskinmanager.getskinchooser(); skincombo.items.add(new radcomboboxitem("metro red", "metrored")); }
now skinchooser
list custom skin 'metro red' along rest of telerik default themes , end user able select preferred theme list.
reference: creating custom skin, telerik forum question on skin chooser, how load skins external assemblies - check out sample project radcustomskinselected
uploaded tsvetoslav
Comments
Post a Comment