Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Specifies properties of the image file used to represent the add-in.
Properties that reference this object type:
- root.extensions.alternates.alternateIcons.highResolutionIcon
- root.extensions.alternates.alternateIcons.icon
- root.extensions.contextMenus.menus.controls.icons
- root.extensions.contextMenus.menus.controls.items.icons
- root.extensions.ribbons.fixedControls.icons
- root.extensions.ribbons.tabs.groups.controls.icons
- root.extensions.ribbons.tabs.groups.controls.items.icons
- root.extensions.ribbons.tabs.groups.icons
Properties that reference this object type:
- root.extensions.alternates.alternateIcons.highResolutionIcon
- root.extensions.alternates.alternateIcons.icon
- root.extensions.ribbons.fixedControls.icons
- root.extensions.ribbons.tabs.groups.controls.icons
- root.extensions.ribbons.tabs.groups.controls.items.icons
- root.extensions.ribbons.tabs.groups.icons
Properties that reference this object type:
Syntax
Properties
size
Specifies the size of the icon in pixels, enumerated as 16
,20
,24
,32
,40
,48
,64
,80
.
Type
number
Required
✅
Constraints
Supported values
Allowed values: 16, 20, 24, 32, 40, 48, 64, 80.
url
Specifies the full, absolute URL of the image file that is used to represent the add-in.
This property is localizable. For more information, see the localization schema.
Type
string
Required
✅
Constraints
Maximum string length: 2048.
Supported values
The string must start with https://
.
Remarks
The ICO file format isn't supported. Using it in your manifest will fail manifest validation and prevent your Office Add-in from appearing in the ribbon or action bar.
When specifying the extensions.alternates.alternateIcons.highResolutionIcon
or extensions.alternates.alternateIcons.icon
properties, the extensionCommonIcon
type works differently from how it works in other contexts, as noted in the following points:
- The icon file must be one of the following file formats: GIF, JPG, PNG, EXIF, BMP, TIFF.
- The
size
property is ignored, but it must be present and have a valid size value. When the manifest is validated, the size of the file in theurl
property is measured. - For the
alternateIcons.icon
property, the file thaticon.url
points to must be 64 x 64 pixels ifmail
is in theextensions.requirements.scopes
array (or there is noextensions.requirements.scopes
property in the manifest). Otherwise, it must be 32 x 32 pixels. - For the
alternateIcons.highResolutionIcon
property, the file thathighResolutionIcon.url
points to must be 128 x 128 pixels ifmail
is in theextensions.requirements.scopes
array (or there is noextensions.requirements.scopes
property in the manifest). Otherwise, it must be 64 x 64 pixels.
Examples
{
"icons": [
{
"size": 16,
"url": "test_16.png"
},
{
"size": 32,
"url": "test_32.png"
},
{
"size": 80,
"url": "test_80.png"
}
]
}
In the following example, the size
properties are ignored, but they must be present and have valid values. When the manifest is validated, the files are opened and measured.
{
"alternateIcons": {
"icon": {
"size": 64,
"url": "https://contoso.com/assets/icon64x64.jpg"
},
"highResolutionIcon": {
"size": 64,
"url": "https://contoso.com/assets/icon128x128.jpg"
}
}
}