We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Ribbon - how to use my own images

Thread ID:

Created:

Updated:

Platform:

Replies:

130437 May 12,2017 01:02 PM UTC May 15,2017 12:36 PM UTC Angular 1
loading
Tags: ejRibbon
Daniel Barisch
Asked On May 12, 2017 01:02 PM UTC

Hi,

how can I use my own image files (e.g. png) with the ribbon contents, e.g. a button?

regards,

Sarath Kumar P [Syncfusion]
Replied On May 15, 2017 12:36 PM UTC

Hi Daniel, 
You can use your own image types with ribbon button using "prefixIcon" or "suffixIcon" properties of ejButton control. Please refer to the below codes and the attached sample. 
[ribbon.component.ts] 
  
groups1 = [{ 
        text: "New", 
        alignType: "rows", 
        content: [{ 
            groups: [{ 
                id: "new", 
                text: "Png Image", 
                toolTip: "Png Image", 
                buttonSettings: { 
                    width: 100, 
                    prefixIcon: "ribbonimg", 
                 contentType: "imageonly" 
                } 
                }], 
            defaults: { 
                type"button", 
                height: 70 
            } 
        }] 
   }] 
  
[src/deps/default.css] 
  
.ribbonimg { 
    backgroundurl(images/Protect.png) no-repeat center; 
    displaytable-cell; 
    height50px; 
    width50px; 
} 
  
  
  
Api Links: 
 
 
 
 
Regards, 
Sarath Kumar P. 
  


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;