Newer Version Available
CustomTab
Represents a custom tab. Display custom object data or other web content using custom tabs in Salesforce. When a tab displays a custom object, the tab name is the same as the custom object name; for page, s-control, or URL tabs, the name is arbitrary. For more information, see “Custom Tabs” in the Salesforce online help. This type extends the Metadata metadata type and inherits its fullName field.
File Suffix and Directory Location
The file suffix is .tab. There is one file for each tab, stored in the tabs folder in the corresponding package directory.
Version
Tabs are available in API version 10.0 and later.
Fields
This metadata type contains the following fields:
| Field Name | Field Type | Description |
|---|---|---|
| actionOverrides | ActionOverride[] |
A list of the action overrides
that are assigned to the tab. Only one override is allowed
per formFactor for a given tab. This field is available in API version 37.0 and later. |
| auraComponent | string |
Indicates whether this tab is for a Lightning component (true) or not
(false). If set to
true, the name of the tab
matches the name of the Lightning component. Only one of these fields should have a value set:
|
| customObject | boolean | Indicates whether this tab is for a custom object (true) or not (false). If set to true, the name of the tab matches the name of the custom object. Only one of these fields should have a value set:
|
| description | string | The optional description text for the tab. |
| flexiPage | string |
The name of the Lightning Page to
display in this tab. Only one of these fields should have a value set:
|
| frameHeight | int | The height, in pixels of the tab frame. Required for s-control and page tabs. |
| fullName | string | The name of the tab. The value of this field depends on the
type of tab, and the API version.
The fullName can contain only underscores and alphanumeric characters. It must be unique, begin with a letter, not include spaces, not end with an underscore, and not contain two consecutive underscores. This field is inherited from the Metadata component. |
| hasSidebar | boolean | Indicates if the tab displays the sidebar panel. |
| icon | string | The optional reference to the image document for the tab if the tab is not using one of the standard tab styles. This is a new field in API version 14.0. |
| label | string | This is the label of the tab, for Web tabs only. |
| mobileReady | boolean | Required. Indicates if the custom tab is available for Mobile Edition (true) or not (false). |
| motif | string | Required. The tab style for the color scheme and icon for the custom tab. For example, “'Custom70: Handsaw,” is the handsaw icon. |
| page | string | The name of the Visualforce page to display in this tab. Only one of these fields should have a value set:
|
| scontrol | string | The name of the s-control to display in this tab. Only one of these fields should have a value set:
|
| splashPageLink | string | The custom link used as the introductory splash page when users click the tab. References a HomePageComponent. |
| url | string | The URL for the external web-page to embed in this tab. Only one of these fields should have a value set:
|
| urlEncodingKey | Encoding (enumeration of type string) | The default encoding setting is Unicode: UTF-8. Change it if you are passing information to a URL that requires data in a different format. This option is available when the value URL is selected in the tab type. |
Declarative Metadata Sample Definition
The following is the definition of a tab:
1<?xml version="1.0" encoding="UTF-8"?>
2<CustomTab xmlns="http://soap.sforce.com/2006/04/metadata">
3 <description>Myriad Publishing</description>
4 <frameHeight>600</frameHeight>
5 <mobileReady>true</mobileReady>
6 <motif>Custom53: Bell</motif>
7 <url>http://www.myriadpubs.com</url>
8 <urlEncodingKey>UTF-8</urlEncodingKey>
9</CustomTab>