Posts

Showing posts with the label Apex

Salesforce Spring '23 - Salesforce Scheduler

                                                Salesforce Scheduler Schedule video appointments with Amazon Chime  Allows for virtual appointments  Enable service resources and customers to view past and upcoming appointments    Improves visibility and organization Use Omni-Channel service resources in Salesforce Scheduler     Allows for scheduling through multiple channels Show available service resources based on engagement channels  Allows for more efficient scheduling Other enhancements Additional improvements to Salesforce Scheduler  

Visualforce for Beginners

Image
Visualforce Basics What is Visualforce? It is a web development framework. Developers can make complex UI both for mobile and desktop which can be hosted on forc.com environment. Visualforce provides access to Salesforce inbuilt features and enables us to extend them and introduce a new or custom functionality. There are some powerful features enabled in visualforce like standardcontroller with help if with we can create awesome new apps from scratch. That’s enough for the background lets dive into coding. Sample Visualforce code: <apex:page standardController=”account” > <apex:form > <apex:pageBlock > <apex:pageBlockSection columns=”1″> <apex:inputField value=”{! account.FirstName}”/> <apex:inputField value=”{! account.LastName}”/> </apex:pageBlockSection> <apex:pageBlockButtons > <apex:commandButton action=”{!save}” value=”Save”/> </apex:pageBlockButtons> </apex:pageBlock> ...

Salesforce Pagination Technical Explanation

Pagination is used to display a list of records from an object in salesforce using standardset controller, Once you done setting up  standardController  attribute then you need to set attribute value to  recordSetVar  attribute value on the same component. recordSetVar  indicates the page uses a list controller. Also we need to use ‘ApexPages.StandardSetController’ in controller extension constructor for inheriting prebuilt salesforce standard object functionality. Now we can see an example on Pagination, Apex Class:- In the below Class, i am getting list of records in constructor using salesforce api method getRecord() and doing an explicit type casting to Account object ‘(Account)controller.getRecord()’ Then in ‘accountRecords’ getter method i am forming a query inside Database.getQueryLocator method which will return me list of accounts whose opportunity is not closed. Again using getAccountPagination() getter method i am retrieving ...