Show Menu
Cheatography

SalesForce Visualforce Page Cheat Sheet by

Global Variables

$Action
global merge field type to use when refere­ncing standard Salesforce actions
$Api
global merge field type to use when refere­ncing API URLs
$Asset
global merge field to use when refere­ncing images and other assets that are part of the Lightning Design System
$Cac­he.O­rg
global merge field to access an org cache from a Visual­force page. Retrieve cached values from a specified partit­ion’s org cache in the referenced org
$Cache.Session
global merge field to access an org’s session cache from a Visual­force page. Retrieve cached values from a specified partit­ion’s session cache in the referenced org.
$Com­pon­ent
global merge field type to use when refere­ncing a Visual­force component
$ComponentLabel
global merge field to use when refere­ncing the label of an inputField component on a Visual­force page that is associated with a message
$Cur­ren­tPage
global merge field type to use when refere­ncing the current Visual­force page or page request
$Fie­ldSet
Provides access to a field set defined in your organi­zation
$Label
global merge field type to use when refere­ncing a custom label
$Lab­el.S­ite
global merge field type to use when refere­ncing a standard Sites label in a Visual­force page. Like all standard labels, the text will display based on the user’s language and locale
$Net­work
global merge field type to use when refere­ncing community details in a Visual­force email template
$Obj­ect­Type
global merge field type to use when refere­ncing standard or custom objects (such as Accounts, Cases, or Opport­uni­ties) and the values of their fields
$Org­ani­zat­ion
global merge field type to use when refere­ncing inform­ation about your company profile. Use organi­zation merge fields to reference your organi­zat­ion’s city, fax, ID, or other details.
$Page
global merge field type to use when refere­ncing a Visual­force page
$Per­mis­sion
global merge field type to use when refere­ncing inform­ation about the current user’s custom permission access. Use permission merge fields to reference inform­ation about the user’s current access to any of your organi­zat­ion’s custom permis­sions
$Pro­file
global merge field type to use when refere­ncing inform­ation about the current user’s profile. Use profile merge fields to reference inform­ation about the user’s profile such as license type or name
$Res­ource
global merge field type to use when refere­ncing an existing static resource by name in a Visual­force page. You can also use resource merge fields in URLFOR functions to reference a particular file in a static resource archive
$SCo­ntrol
global merge field type to use when refere­ncing an existing custom s-control by name. This merge field type results in a URL to a page where the s-control executes
$Setup
global merge field type to use when refere­ncing a custom setting of type “hiera­rchy.”
$Site
global merge field type to use when refere­ncing inform­ation about the current Salesforce site
$Sys­tem.Or­igi­nDa­teT­ime
global merge field that represents the literal value of 1900-01-01 00:00:00
$User
global merge field type to use when refere­ncing inform­ation about the current user. User merge fields can reference inform­ation about the user such as alias, title, and ID. Most of the fields available on the User standard object are also available on $User
$User.UITheme
$User.UIThemeDisplayed
global merge fields identify the Salesforce look and feel a user sees on a given Web page
$Use­rRole
global merge field type to use when refere­ncing inform­ation about the current user’s role. Role merge fields can reference inform­ation such as role name, descri­ption, and ID
 

HowTo

Use global variables to reference general inform­ation about the current user and your organi­zation on a page.
Global variables must be referenced using Visual­force expression syntax to be evaluated, for example, {!$Use­r.F­irs­tName}.
Visualforce Developer Guide

Help Us Go Positive!

We offset our carbon usage with Ecologi. Click the link below to help us!

We offset our carbon footprint via Ecologi
 

Comments

No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets