Skip to main content

Notifications

Microsoft Dynamics 365 | Integration, Dataverse...
Answered

unified interface not able to add icon in the ribbon.xml file in contact entity

Posted on by 70

Unified Interface Env 

pastedimage1601309060283v1.png

here I want to update the icon Add to Marketing List ,

So in the contact Entity Ribbon.xml file my code 

<CustomAction Id="tre.contact.Button2.Button.CustomAction" Location="Mscrm.HomepageGrid.contact.MainTab.Collaborate.Controls._children" Sequence="10">
<CommandUIDefinition>
<Button Alt="$LocLabels:tre.contact.Button2.Button.Alt" Command="tre.contact.AddtoMarketingList.Command" Id="tre.contact.Button2.Button" Image32by32="/uclient/resources/images/Add.svg" Image16by16="/uclient/resources/images/Add.svg" LabelText="$LocLabels:tre.contact.Button2.Button.LabelText" Sequence="10" TemplateAlias="o1" ToolTipTitle="$LocLabels:tre.contact.Button2.Button.ToolTipTitle" ToolTipDescription="$LocLabels:tre.contact.Button2.Button.ToolTipDescription" />
</CommandUIDefinition>
</CustomAction>
<CustomAction Id="tre.contact.Button3.Button.CustomAction" Location="Mscrm.SubGrid.contact.MainTab.Collaborate.Controls._children" Sequence="10">
<CommandUIDefinition>
<Button Alt="$LocLabels:tre.contact.Button3.Button.Alt" Command="tre.contact.AddtoMarketingList.Command" Id="tre.contact.Button3.Button" Image32by32="/uclient/resources/images/Add.svg" Image16by16="/uclient/resources/images/Add.svg" LabelText="$LocLabels:tre.contact.Button3.Button.LabelText" Sequence="10" TemplateAlias="o1" ToolTipTitle="$LocLabels:tre.contact.Button3.Button.ToolTipTitle" ToolTipDescription="$LocLabels:tre.contact.Button3.Button.ToolTipDescription" />
</CommandUIDefinition>
</CustomAction>
<CustomAction Id="tre.contact.Button4.Button.CustomAction" Location="Mscrm.Form.contact.MainTab.Save.Controls._children" Sequence="61">
<CommandUIDefinition>
<Button Alt="$LocLabels:tre.contact.Button4.Button.Alt" Command="tre.contact.AddtoMarketingListOnContact.Command" Id="tre.contact.Button4.Button" Image32by32="/uclient/resources/images/Add.svg" Image16by16="/uclient/resources/images/Add.svg" LabelText="$LocLabels:tre.contact.Button4.Button.LabelText" Sequence="61" TemplateAlias="o1" ToolTipTitle="$LocLabels:tre.contact.Button4.Button.ToolTipTitle" ToolTipDescription="$LocLabels:tre.contact.Button4.Button.ToolTipDescription" />
</CommandUIDefinition>
</CustomAction>

But in the UI the icon is not getting 

 

pastedimage1601309295593v2.png

so  I have import the solution in the ribbon work bench and i am able to see plus icon image but in the UI I am not able to see 

pastedimage1601309364601v3.png No Icon found. 

Even I am giving same id see my html code 

pastedimage1601309519579v4.png

  • Verified answer
    RE: unified interface not able to add icon in the ribbon.xml file in contact entity

    Hi Ravindra, 

    Note that you must use a .svg icon file in the WebResource used in ModernImage, a .png file will not work.

  • Ravi@thomson Profile Picture
    Ravi@thomson 70 on at
    RE: unified interface not able to add icon in the ribbon.xml file in contact entity

    Hello ,

    Now I am defining the tag ModernImage  but still same issue

    <CustomAction Id="tre.contact.Button2.Button.CustomAction" Location="Mscrm.HomepageGrid.contact.MainTab.Collaborate.Controls._children" Sequence="10">

         <CommandUIDefinition>

           <Button Alt="$LocLabels:tre.contact.Button2.Button.Alt" Command="tre.contact.AddtoMarketingList.Command" Id="tre.contact.Button2.Button" Image32by32="/_imgs/ribbon/AddToMarketingList_32.png" Image16by16="/_imgs/ribbon/AddToMarketingList_16.png" ModernImage="/_imgs/ribbon/AddToMarketingList_16.png" LabelText="$LocLabels:tre.contact.Button2.Button.LabelText" Sequence="10" TemplateAlias="o1" ToolTipTitle="$LocLabels:tre.contact.Button2.Button.ToolTipTitle" ToolTipDescription="$LocLabels:tre.contact.Button2.Button.ToolTipDescription" />

         </CommandUIDefinition>

       </CustomAction>

       <CustomAction Id="tre.contact.Button3.Button.CustomAction" Location="Mscrm.SubGrid.contact.MainTab.Collaborate.Controls._children" Sequence="10">

         <CommandUIDefinition>

           <Button Alt="$LocLabels:tre.contact.Button3.Button.Alt" Command="tre.contact.AddtoMarketingList.Command" Id="tre.contact.Button3.Button" Image32by32="/_imgs/ribbon/AddToMarketingList_32.png" Image16by16="/_imgs/ribbon/AddToMarketingList_16.png" ModernImage="/_imgs/ribbon/AddToMarketingList_16.png" LabelText="$LocLabels:tre.contact.Button3.Button.LabelText" Sequence="10" TemplateAlias="o1" ToolTipTitle="$LocLabels:tre.contact.Button3.Button.ToolTipTitle" ToolTipDescription="$LocLabels:tre.contact.Button3.Button.ToolTipDescription" />

         </CommandUIDefinition>

       </CustomAction>

       <CustomAction Id="tre.contact.Button4.Button.CustomAction" Location="Mscrm.Form.contact.MainTab.Save.Controls._children" Sequence="61">

         <CommandUIDefinition>

           <Button Alt="$LocLabels:tre.contact.Button4.Button.Alt" Command="tre.contact.AddtoMarketingListOnContact.Command" Id="tre.contact.Button4.Button" Image32by32="/_imgs/ribbon/AddToMarketingList_32.png" Image16by16="/_imgs/ribbon/AddToMarketingList_16.png" ModernImage="/_imgs/ribbon/AddToMarketingList_16.png" LabelText="$LocLabels:tre.contact.Button4.Button.LabelText" Sequence="61" TemplateAlias="o1" ToolTipTitle="$LocLabels:tre.contact.Button4.Button.ToolTipTitle" ToolTipDescription="$LocLabels:tre.contact.Button4.Button.ToolTipDescription" />

         </CommandUIDefinition>

    and ribbon work bench i am able to see but after publish it is not coming .

    pastedimage1601348158910v1.png

  • Suggested answer
    RE: unified interface not able to add icon in the ribbon.xml file in contact entity

    Hi Ravi, 

    Note that image16 and Image32 are used to define only the icons in the legacy/classic Web interface ( .png web resources icons). To define the svg icon in the Unified Interface Client ( UCI) you need to define it in the tag ModernImage

    See blogs below for more details:

    https://d365demystified.com/2019/05/31/fix-ribbon-icons-on-the-unified-interface-in-d365-ce/ 

    https://carldesouza.com/how-to-set-button-icons-in-unified-interface-and-dynamics-365-power-apps/

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Complete!

🔔 Be sure to subscribe to the new forums you are interested in to stay up to date! 🔔

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,113 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 229,918 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans