Renders a canvas app identified by the given developerName/namespacePrefix or applicationName/namespacePrefix value pair. The developerName attribute takes precedence if both developerName and applicationName are set.
Note: The canvas app is rendered within a div element, the div element id can be retrieved by {!$Component.genContainer}. <apex:page showHeader="false"> <apex:canvasApp developerName="canvasAppDeveloperName"/> </apex:page>
<apex:page showHeader="false"> <apex:canvasApp applicationName="canvasAppName"/> </apex:page>
<apex:page showHeader="false"> <apex:canvasApp developerName="canvasAppDeveloperName" namespacePrefix="fromDevOrgNamespacePrefix"/> </apex:page>
<apex:page showHeader="false"> <apex:canvasApp applicationName="canvasAppName" namespacePrefix="fromDevOrgNamespacePrefix"/> </apex:page>
<apex:page showHeader="false"> <apex:outputPanel layout="block" id="myContainer"> <apex:canvasApp developerName="canvasAppName" namespacePrefix="fromDevOrgNamespacePrefix" containerId="{!$Component.myContainer}"/> </apex:outputPanel> </apex:page>
Attribute Name | Attribute Type | Description | Required? | API Version | Access |
---|---|---|---|---|---|
applicationName | String | Name of the canvas app. Either applicationName or developerName is required. | 33.0 | ||
border | String | Width of the canvas app border, in pixels. If not specified, defaults to 0 px. | 33.0 | ||
canvasId | String | Unique ID of the canvas app window. Use this attribute when targeting events to the canvas app. | 33.0 | ||
containerId | String | An HTML element ID in which the canvas app is rendered. If not specified, defaults to null. The container specified by this can't appear after the <apex:canvasApp> component. | 33.0 | ||
developerName | String | Developer name of the canvas app. This name is defined when the canvas app is created and can be viewed in the Canvas App Previewer. Either developerName or applicationName is required. | 33.0 | ||
entityFields | String | Specifies the fields returned in the signed request Entity
object when the component appears on a Visualforce page placed on an
object. If this attribute isn’t specified or is blank, then
only Id and type information is provided. Valid attribute values
include:
|
33.0 | ||
height | String | Canvas app window height, in pixels. If not specified, defaults to 900 px. | 33.0 | ||
id | String | An identifier that allows the component to be referenced by other components in the page. | 14.0 | global | |
maxHeight | String | The maximum height of the Canvas app window in pixels. Defaults to 2000 px; 'infinite' is also a valid value | 33.0 | ||
maxWidth | String | The maximum width of the Canvas app window in pixels. Defaults to 1000 px; 'infinite' is also a valid value | 33.0 | ||
namespacePrefix | String | Namespace value of the Developer Edition organization in which the canvas app was created. Optional if the canvas app wasn’t created in a Developer Edition organization. If not specified, defaults to null. | 33.0 | ||
onCanvasAppError | String | Name of the JavaScript function to be called if the canvas app fails to render. | 33.0 | ||
onCanvasAppLoad | String | Name of the JavaScript function to be called after the canvas app loads. | 33.0 | ||
parameters | String | Object representation of parameters passed to the canvas app. This should be supplied in JSON format or as a JavaScript object literal. Here’s an example of parameters in a JavaScript object literal: {param1:'value1',param2:'value2'}. If not specified, defaults to null. | 33.0 | ||
rendered | Boolean | A Boolean value that specifies whether the component is rendered on the page. If not specified, this value defaults to true. | 14.0 | global | |
scrolling | String | Specifies whether the canvas app window should use scroll bars. Valid values are auto|yes|no. If not specified or set to an invalid value, it will default to no. | 33.0 | ||
width | String | Canvas app window width, in pixels. If not specified, defaults to 800 px. | 33.0 |