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

How to use the Telerik icons in HTML?

2 Answers 165 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Rini Boo
Top achievements
Rank 1
Rini Boo asked on 04 May 2010, 07:19 PM

I read this http://www.telerik.com/help/aspnet-ajax/grdskins.html  and it seems I can use the Telerik icons in HTML, I need to do some customization on RadGrid.

 

Anyone knows how to use it in an ASPX page?  Since it is already embedded in web resource already.

<img  src="......[some web resource path]....Edit.gif" />

Of course the stupid way is to download all images in my web application and reference it as   ~/Images/Edit.gif.   


Thanks

 

 

2 Answers, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 04 May 2010, 09:57 PM
Hello Rini,

A sample code is shown below:
<img src='<%= ClientScript.GetWebResourceUrl(RadGrid1.GetType(), "Telerik.Web.UI.Skins.Telerik.Grid.Edit.gif") %>'
   alt="Edit" />

Hope this helps.

Regards,
Daniel
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Rini Boo
Top achievements
Rank 1
answered on 05 May 2010, 01:58 PM
Thanks that works!  To further help other people on the forum,  if you need to use ImageButton, you need to use single quote + data binding syntax. Also, you may need to put "Page.ClientScript" in some cases.

 

<asp:ImageButton runat="server" ImageUrl='<%# Page.ClientScript.GetWebResourceUrl(RadGrid1.GetType(), "Telerik.Web.UI.Skins.Telerik.Grid.Edit.gif") %>' />  
 

If you want to use other skin, for example "Outlook2007" with "AddRecord" icon, you can do the following. Refer to the build-in skins documentation, there are 14 of them:

Telerik.Web.UI.Skins.Office2007.Grid.AddRecord.gif 
Tags
Grid
Asked by
Rini Boo
Top achievements
Rank 1
Answers by
Daniel
Telerik team
Rini Boo
Top achievements
Rank 1
Share this question
or