Newer Version Available

This content describes an older version of this product. View Latest

FlexiPage

Represents a Flexible Page. A Flexible Page is the home page for an app that appears as a menu item in the Salesforce1 navigation menu. Includes access to the associated FlexiPage object in the Salesforce Metadata API.

Available from API version 31.0 or later.

Supported SOAP Calls

create()query()retrieve()update()upsert()

Supported REST HTTP Methods

GET, HEAD

Fields

Field Details
DeveloperName
Type
string
Properties
Create, Filter, Group, Sort, Update
Description
The API name of the Flexible Page.
FullName
Type
string
Properties
Group, Nillable.
Description
The full name of the associated FlexiPage object in Metadata API.
LastModifiedDate
Type
dateTime
Properties
Filter, Sort.
Description
Last modified date.
Metadata
Type
FlexiPageMetadata
Properties
Create, Nillable, Update.
Description
Flexible Page metadata.
NamespacePrefix
Type
string
Properties
Filter, Group, Nillable, Sort.
Description
The namespace prefix.

Sample Code

This code sample creates a new Flexible Page with a single Recent Items component, that shows recently used Accounts and MyCustomObject__cs

1swfobject.registerObject("clippy.codeblock-0", "9"); ComponentInstance recentItems = new ComponentInstance();
2 recentItems.setComponentName("flexipage:recentItems");
3 ComponentInstanceProperty cip = new ComponentInstanceProperty();
4 cip.setName("entityNames");
5 cip.setValue("Account,MyCustomObject__c");
6 recentItems.setComponentInstanceProperties(new ComponentInstanceProperty[]{cip});
7
8FlexiPageRegion mainRegion = createRegion("main");
9mainRegion.setComponentInstances(new ComponentInstance[] { recentItems });
10
11FlexiPageMetadata fpMetadata = new FlexiPageMetadata();
12fpMetadata.setFlexiPageRegions(new FlexiPageRegion[]{mainRegion});
13fpMetadata.setMasterLabel("My FlexiPage");
14fpMetadata.setDescription("A FlexiPage with a recent items component");
15
16FlexiPage flexiPage = new FlexiPage();
17flexiPage.setFullName("MyFlexiPageDevName");
18flexiPage.setMetadata(fp);
19
20// Create
21SaveResult saveResult = soapConnection.create(new SObject[] { flexiPage });