Wednesday, December 26, 2012

Rich Visualforce Editor Updates

Hi Guys, I am happy to announce new version of Rich Visualforce Plugin. I have added some exciting features to this release. The major change is you can use it with standalone version of IDE.

Major features of this release:-

  • GIT Integration (it helps you to push your code to git repository on Ctrl+S key press.)
  • Added support for new visualforce tags.
  • Plugin works well with both IDE as well as eclipse plugins.

GIT Integration IDE/Plugin never supported code versioning and many times I felt its necessity and added a new feature to this release. Now you can configure your project with GIT repository and this plugin provides git push on save event of apex page and class.

Added new visualforce tags support
Now plugin supports visulaforce tags introduced till 26 version of the API

Friday, December 14, 2012

Code snippet for salesforce multiselect picklist

Salesforce Multiselect Picklist

Hi Guys, we generally use multiselect picklist in salesforce here is an example of multiselect picklist.. which allows to show fields based on selected options.

see running example on 

<apex:page controller="MultiselectExample">
  <!-- Begin Default Content REMOVE THIS -->
  <apex:form id="form">
  <div style="border:1px solid gray;width:100%;float:left;">
    <div style="border:1px solid gray;width:50%;float:left;">
        <apex:panelGrid columns="3" id="multipicklistbox">
            <apex:selectList id="sel1" value="{!leftselected}" multiselect="true" style="width:200px" size="8">
                <apex:selectOptions value="{!leftBoxValues}" />
                <apex:panelGroup >
                    <apex:commandButton value=">" action="{!addtoLeftBox}" reRender="form" title="Select Objects"/>
                    <apex:commandButton value="<" action="{!addtoRightBox}" reRender="form" title="Deselect Objects"/>
            <apex:selectList id="sel2" value="{!rightselected}" multiselect="true" style="width:200px" size="8">
                <apex:selectOptions value="{!rightBoxValues}" />
         <apex:inputText id="other" label="Other Text" rendered="{!IsOtherOptionSelected}"/>
    <div style="border:1px solid gray;width:48%;float:left;">
    <apex:outputPanel id="selectedItems">
    <apex:commandButton value="Print Selected" reRender="selectedItems"/>

---------- MultiSelectExample.cls------------------

public class MultiselectExample {
    Public List<string> leftSelected{get;set;}
    Public List<string> rightSelected{get;set;}
    Set<string> leftValues = new Set<string>();
    Set<string> rightValues = new Set<string>();
    Set<string> selectedObjects = new Set<string>();
    public MultiselectExample(){
        for(integer i=0;i<10;i++){
            leftValues.add('selectList Item '+i);
        leftValues.add('Other Value');
    /* Add item to rightbox of picklist*/
    public PageReference addtoLeftBox(){
        for(String s : leftSelected){
        return null;
    /* Add item to leftbox of picklist*/
    public PageReference addtoRightBox(){
        for(String s : rightSelected){
        return null;

        /* return rightbox values of picklist */
    public List<SelectOption> getLeftBoxValues(){
        List<SelectOption> options = new List<SelectOption>();
        List<string> tempList = new List<String>();
        for(string s : tempList)
            options.add(new SelectOption(s,s));
        return options;
        /* return leftbox values of picklist */
    public List<SelectOption> getRightBoxValues(){
        List<SelectOption> options1 = new List<SelectOption>();
        List<string> tempList = new List<String>();
        for(String s : tempList)
            options1.add(new SelectOption(s,s));
        return options1;
    public Boolean getIsOtherOptionSelected(){
        Boolean retValue = false;
        for(String selObj: rightValues ){
                return true;
        return retValue;
    public PageReference printSelectedValues(){
        return null;

Tuesday, June 26, 2012

Rich Visualforce Editor

Hi Guys, I started learning platform in November 2011, After few days I got frustrated with eclipse IDE. Reasons we all know well, no auto complete, no context sensitive help, no versioning support,  no active development for this plugin.

Being a Java guy I decided to write a new eclipse plugin to fill this gape so started an open source project on github with name “Rich Visualforce Editor”. After some research and development & little hard work I released alpha version of that plugin, later I couldn’t keep this progress continue and released only one more update with couple of more features and bug fixes. But now I decided to start working on this again with some new features list.

My friend Abhinav Gupta, he motivated me to write this plugin for community, I am very thankful of him. He published couple of posts on his blogs to introduce this plugin to community, you can read following posts from his blog.