Hi i'm working on a sharepoint Addin i wanna create a custom ribbon button using javascript , i tryed with xml it's work fine using this code :
--><?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<CustomAction Id="e3ae8fc7-7989-467c-ba5f-6bdb1d5064c3.AzeoFullDownload"
RegistrationType="List"
RegistrationId="101"
Location="CommandUI.Ribbon"
Sequence="10001"
Title="Invoke 'AzeoFullDownload' action">
<CommandUIExtension>
<!--
Update the UI definitions below with the controls and the command actions
that you want to enable for the custom action.
-->
<CommandUIDefinitions>
<CommandUIDefinition Location="Ribbon.Documents.Copies.Controls._children">
<Button Id="Ribbon.Documents.Copies.AzeoFullDownloadButton"
Alt="AzeoFullDownload"
Sequence="100"
Command="Invoke_AzeoFullDownloadButtonRequest"
LabelText="AzeoFullDownload"
TemplateAlias="o1"
Image32by32="images/Button-Download.png"
Image16by16="images/Button-Download.png" />
</CommandUIDefinition>
</CommandUIDefinitions>
<CommandUIHandlers>
<CommandUIHandler Command="Invoke_AzeoFullDownloadButtonRequest"
CommandAction="~appWebUrl/Pages/Default.aspx?{StandardTokens}&SPListItemId={SelectedItemId}&SPListId={SelectedListId}"
EnabledScript="javascript:EnableCopyLinkToClipboard();"/>
</CommandUIHandlers>
</CommandUIExtension >
</CustomAction>
<!--
<CustomAction
Id="CopyLinkToClipboardScript"
Location="ScriptLink"
ScriptSrc ="~appWebUrl/Pages/App.js"/> -->
</Elements>
thank you