Salesforce

CreatedDate in test classes

Finally Salesforce fills the gap and allows you to specify the createddate field within test classes. You only have to use the Test.setCreatedDate method introduced with Spring ’16.

Better late than never!

Salesforce

Spring ’16

Spring ’16 release is already among us. I was able to attend the 4 webcasts where the most important features were presented with nice demonstrations. I recommend you to join the Release Readiness Chatter group. There are very interesting documents, including the release notes for this release but also for past and future releases. Once…

Salesforce

Manage UserTerritory table through REST API

UserTerritory is one of the few objects that don’t allow DML Operations. However, we can manage it through the REST API. We could assign a User to a Territory by using the following APEX code:

If you want to remove a user from a territory, then the APEX code would looks like the following:…

Salesforce

Defensive future calls

I would like to talk about the wonderful and simple pattern for making future calls. This pattern was presented by Dan Appleman at one of his sessions at Dreamforce this year. It looks like this:

Simple but very effective. To provide you a quick example. Let’s suppose we have a Session object and a…

Salesforce

Using JWT to share data between Orgs

Let’s suppose we want to show some records in our Salesforce Org, let’s call this Org “A”, but this information is stored in another Salesforce Org, “B”. There are several ways to accomplish this requirement. We could use Salesforce-to-Salesforce to share records between different Orgs. We could also use third-party tools like Informatica Cloud or…

www.000webhost.com