Category: Visualforce
Visualforce Row Counter for Iteration Components
April 2nd, 2010, 2 Comments
I have been working on a Visualforce page that displays a list of items from a collection and I want to display the current row number next to each item. I found this post that describes a solution but I think there may be a bug in one of the components so here is proposed [...]
Passing Parameters with a CommandButton
March 4th, 2010, 6 Comments
This post is a slight tweak of yesterday’s post, Passing Parameters with a CommandLink. In theory you should just be able to switch out the CommandLink component with a CommandButton component and be golden. However, not so fast. There seem to still be a bug with the CommandButton component. Here is the Visualforce page with [...]
Passing Parameters with a CommandLink
March 3rd, 2010, 5 Comments
Here’s a small example of how you can pass a value to another method via a command link for Salesforce.com. When the link is clicked, the setter fires for the public member nickName. The button click then calls the processLinkClick method where you can do something like process the variable further with DML statement or [...]
Using List Custom Settings in Salesforce.com
January 7th, 2010, 25 Comments
Salesforce.com recently introduced Custom Settings in Winter ’10 which allows you to store custom data sets and associate them on an org-wide, profile or user basis. Custom Settings are essentially custom objects that are exposed in the applications cache and are accessible via their own API. You can certainly build your own custom objects to [...]
Calling a REST Web Service (JSON) with Apex
January 6th, 2010, 7 Comments
Cross-posted at the Appirio Tech Blog. Using JSON RESTful Web Services with Salesforce.com opens up your org to a number third-party integration opportunities (Google, Yahoo!, Flickr, bespoke, etc.). JSON support isn’t baked into the Force.com platform but Ron Hess at Salesforce.com has created a JSON parser which will do the heavy lifting for you. Last [...]
Using Relationships in Visualforce Pages
December 16th, 2009, 3 Comments
The topic of relationships in Visualforce pages came up on the Salesforce developer discussion boards the other day so I thought I’d throw something together to expand on the topic. Let’s say you want to print off a Sales Order or Purchase Order as a PDF. You can use the parent and child relationships inherent [...]
Calling a REST Web Service (XML) with Apex
December 4th, 2009, 4 Comments
This is a cool little example of calling a REST web service with Apex. You enter your address and the Apex code fetches the geo coordinates from Yahoo! Maps. The service returns the data as XML. If you want to run this demo in your own org, you will need to do the following: Add [...]
Force.com Demo with Twilio
November 28th, 2009, No Comments
Cross-posted at the Appirio Tech Blog. During Dreamforce 09 Kyle Roche and I participated in the Developer Hackathon. We hacked-up an application using Force.com and Twilio for inbound and outbound calling. We were only allotted two hours so we were not able to finish off the application during the hackathon. Here is the final demo [...]
Apex “Deep Clone” Controller
November 19th, 2009, 4 Comments
I wrote the following code at the Admin To Hero App Building Workshop and it was very popular. I think we used the code on 3 or 4 projects that day so I thought I’d post it to help everyone out. Essentially it is a Visualforce page and Apex Controller that allows you to do [...]
ActionSupport Example using Facets and JavaScript
November 6th, 2009, No Comments
You can make your UI much easier on your users by giving them clues on what is taking place when they click buttons, enter text or choose items in a picklist. This example shows how you can notify a user that something is taking place in the background when you are performing actions asynchronously. For [...]










