I have shared “Approval Processing with Apex in Salesforce” in previous post, and in this post, I’ll continue to share the way of bulk approval processing from Salesforce list view. The outline we need to do is as below : ・Add a custom button for list view ・Set List View Layout ・Add a Apex Class […]

An approval process is an automated process your organization can use to approve records in Salesforce. Usually we can request/approve an approval process through the standard approval process feature, but we can also do those things with Apex in some cases such as : request/approve from VF Page or from Custom Button. Here is Approval […]

ContentDocument object does not allow insert DML operation in Salesforce, but we can create it through the ContentVersion object, without ContentDocumentId, then a new version of ContentDocument will be created for us in SFDC, just like the sample code below :

In Salesforce,DML operation is not allowed on CategoryNode sObject,even in Unit Test. Although the 《Force.com Apex Code Developer’s Guide》 does not mention it clearly,that CategoryNode object can be accessed in Apex Tests, we have to prepare CategoryNode data first in Setup interface.by clicking Customize > Solution > Solution Categories. The following is the sample code […]

Let’s see the following Apex Script first. In fact the Apex Script will throw an AssertException. “System.AssertException: Assertion Failed: Expected: 0E-32%, Actual: 0%”. So we’d better round the Decimal before we convert it to String.Like the following Apex Script.

Well,this is another Salesforce Trigger framework but more simple. Usage AccountTriggerHandler.cls AccountTrigger.trigger In normal case. Stop and resume sObject Trigger in APEX code Stop and resume a TriggerHandler in APEX code SourceCode Download from Github That is all, Enjoy it!