I am having a visualforce page where i display a multi select picklist field. It's a InputField so the user can change the value of the field and then save it. The problem is that when i choosing nothing in the multi select picklist field and save it still gives me one value at the "Chosen" side. Any ideas why? by the way, with standard pick-list field i don't have this problem...

i have checked the "save" class in my controller and it seems that the problem is with the: pageRef.setRedirect(true) i use but without it i the page is not refreshing automatically after the saving... this is the full "save" class which i use:

public PageReference save() {
    update Pos;
    PageReference pageRef = new PageReference(ApexPages.currentPage().getUrl());
    return pageRef;

Thx in advanced

  • I think we need to see more code to understand what's happening. However, first thing is that I would expect you to return a null PageReference from the save() method. Also, do you have a <apex:pagemessages /> tag that is being rerendered on your page? – Jeremy Nottingham Aug 30 '14 at 7:31

Have you defined your Mult-Select picklist field with a default value?

enter image description here

Have you also tried returning 'null' from your action method?

| improve this answer | |
  • No, i dont have a default value. As i wrote, the problem is with the "setRedirect" function which i need to for the page refresh. so, acctualy, my question is 1. why this function making this problem(non-null option in multyselect field)? it just seem to have no connection between the two.. 2. do i have other option for refreshing the vf page after saving? thx! – noam Dec 3 '13 at 20:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.