instanceof Keyword in Salesforce Apex
Using Salesforce Apex, if you want to verify at run time or dynamically whether an object is actually an instance of a particular class, then we can make use of ....
Using Salesforce Apex, if you want to verify at run time or dynamically whether an object is actually an instance of a particular class, then we can make use of ....
Apex can be executed synchronously or asynchronously.Synchronous:In a Synchronous call, the thread will wait until it completes its tasks before proceeding to next. In a Synchronous call, the code runs ....
length() method can be used to find the length of the String using Apex in Salesforce. Sample Code: String myStr = 'abcdef'; Integer result = myStr.length(); System.debug( 'Result is ' + ....
Simple Replace Code: String str = 'RAM'; System.debug( 'Replace value is ' + str.replace( 'A', 'O' ) ); Output: Sample Multi-Level or multiple characters replace Code: String str = 'test'; ....
format() will remove the time stamp from Date. Sample Code: Date dat = System.Today(); System.debug(dat.format()); format() is used to get Date from Datetime using Salesforce Apex.
To get Session Id using Apex in Salesforce, UserInfo.getSessionId() is used. Sample Code: String sessionId = UserInfo.getSessionId(); Note: For Apex code that is executed asynchronously, such as @future methods, Batch Apex ....
UserInfo.getOrganizationId() can be used to fetch the Salesforce organization id using Apex. Sample Code: Id OrgId = UserInfo.getOrganizationId(); System.debug( 'Org Id is ' + OrgId ); UserInfo.getOrganizationId() allows us to ....
escape attribute in Salesforce Visualforce is used to determine whether the HTML and XML characters should be escaped in the HTML output generated by the component or not. For example, ....
getOrgDomainUrl() can be used in Salesforce Apex to get your org URL. getCurrentRequestUrl() can used in Salesforce Apex to get the URL of an entire request on a Salesforce instance. ....
isNumeric() can be used to check whether a string is numeric using Apex in Salesforce. Sample Code: String str = 'abc'; if ( str.isNumeric() ) { Integer intVal = Integer.ValueOf( ....