Thursday, August 14, 2014

Quick Tips: Merge fields in Visualforce

As most of my colleagues know me, I have always struggled to remember fieldnames, action names and have hard time copying names of fields from Object detail page and put them onto a Visualforce page, while creating merge fields.

I just wanted to share a small tip for all those who share my "struggle" and want to have an easy way to get around that.

If you are an eclipse user, plugin comes up with a very handy tool. Following are the tips to use it:-

  1. Open visualforce page in eclipse
  2. Open right click menu
  3. Click on> Insert Merge Field
  4. Voilla, you have all the objects listed in left hand list and on selecting an object, their fields gets populated in right hand list (as shown below)

Quick Tips: Merge fields in Visualforce: Insert fields

Additionally, you can also lookup standard actions available by selecting "$Actions" in the left hand list and it would display a list of all actions available (as per screenshot below):-
Quick Tips: Merge fields in Visualforce: Insert actions

Hope this helps your visualforce development and don't make you depend on memory pills.

Popular Posts