Salesforce. AI. Web3
Accessing Sobject Field Sets in Apex Code !
I recently came across a problem, where I need to query the fields to be shown via FieldSet via Apex Code (No Standard Controller Love). After struggling for a while with Apex docs, I googled for the same…
Fighting and Fixing the “MIXED_DML_OPERATION” Error!
You can easily run into this error if you are trying to perform DML on setup and non-setup objects in the same transaction. Non-Setup objects can be any one of the standard objects, like Account or any custom object.
Here are a few examples of the Setup Objects:
Tip: Using Decimal class with Strings in Apex
Today I came across an interesting problem that reminded me of my Java days. A piece of Apex code written by some other developer was broken, when I did my fixes.
Here is some background about the broken…
Force.com Developer Console Navigation Trick
I never thought that working in browser can be more fun than Eclipse IDE. But my thinking is changing these days, first http://jsfiddle.net/ became my favorite playground for any HTML/Javascript research…
Salesforce Email Services: Where is the "Delete" button?
Deletion of email services is interesting. One of my team members recently approached me, asking why the “DELETE” button is not coming on configured in email services.
Resolved: “Field is not writeable: Sobject__Share.RowCause”!
This post is about an issue that comes with Apex-managed sharing, i.e. System.SObjectException: Field is not writeable: Sobject__Share.RowCause. We faced this problem recently and tried searching…
Yet Another Apex Trigger Template!
I know Trigger templates are previously discussed also in great detail. We have excellent posts available by Steve Andersen(Gokubi) and Mike Leach on the same. Here is my small journey on Triggers…
Force.com ESAPI v0.5 & Death of Apex-CRUD-FLS-Validator API
To merge these Apex-CRUD-FLS-Validator APIs with Force.com ESAPI, I discussed with Yoel Gluck. Yoel maintains the Google Code project for ESAPI and is “Salesforce's Lead Product Security Engineer”. In our discussions about adding these new APIs to the Force.com ESAPI project, we devised a plan to merge the APIs…
Rich Visualforce Editor that finally supports Content Assist !
We all miss content assist support in Force.com IDE Visualforce editor. My previous attempt of using eclipse code templates was a patch to fill this gap. Good news now is, my colleague @AjayHada is creating a Visualforce editor, that will give decent code assistance support on…
Visualforce Code Templates/Snippets for Force.com IDE!
Force.com IDE is already doing a decent job on top of Eclipse. It provides a nice Visualforce editor with syntax highlighting and code indentation based on the standard Eclipse HTML Editor. I recently tried to create a couple of Visualforce code templates/snippets to quickly assist in creating the pages and was successful in that attempt. The rest of the post describes how.
JSON parsing in Apex, a developer’s nightmare :( Winter’12 release I badly need you !
Today I stumbled upon a requirement to parse JSON in Apex. I was happy about the fact that I know there is a cool open source library calledJSONObject, that will do all the heavy lifting of JSON parsing and another more cooler native JSON parser is lined up in coming winter'12 release…
Dependency Injection for ease in Testing Apex WebService Callouts!
Dear Apex developers, who are using HTTP Restful Classes know that testing the callouts is not allowed in Apex. People came up with their own smart ways to handle this restriction.
Apex inheritance – Extending managed package abstract/virtual classes & interfaces !
n my recent project, I came across a requirement to create a base class in a managed package with child extension packages would extend to add their value to it…
Sorting Apex SelectOption Array/List
All Apex developers creating Visualforce pages with drop-downs and checkboxes use the Apex SelectOption class. On most occasions, instances of this class are created out of records in a database that we can query in a desired alphabetical order
Calling Marketo SOAP API from Salesforce APEX Classes !
We know about Marketo and its having a deep Salesforce integration. Recently I came across a new requirement to call Marketo SOAP API from Apex. You must be thinking this process is pretty straightforward…
Preparing for Salesforce AppExchange Security Review!
This post is for guys who are planning to release their app on App Exchange and are looking forward to clearing the security review in one shot! This post aggregates all the good links and information you should have in hand.
Force.com ESAPI: A Key to Simplifying Apex Security Compliance!
While fixing security issues for a customer, I came across a very interesting and powerful security API from Salesforce, i.e., Force.com ESAPI. As per the Google code description, this API…
How do you read cookies set by JavaScript in the Apex/Visualforce controller?
This might be a requirement, if you are developing some complex navigation…