0

I am using Bootstrap and have two apex:selectList next to each other in bootstrap row(6,6). I am using two different variable for values for both of them and initializing them in constructor.The problem is select list show the same values in both of the selectList.

however, when the print variable on page by simply {!value1} {!value2} , then it shows the right values but apex:selectlist shows the same values based on whatsoever is declared first. I did put a command button and rerender the section again, then it shows the different values . but on page load, it pick the same values for both of them , whomsoever is defined first.

Both the apex list shows 180 but the values just under them are different. 180 in first and 188 in second.. If I reverse the postion of apex:select list them both will show 188. enter image description here

<div class="row top1" id="guDiv">
              <div class="col-xs-5" style="text-align: left;">
                 <apex:outputPanel id="genabilityUR">
                        <apex:selectList style="width:100%;" styleClass="selectinline" id="elecrate" size="1" value="{!electricratecurrentselected}" disabled="{!!ratesEdited}" multiselect="false">
                            <apex:selectOptions value="{!ElectricUsageRate}"/>
                    </apex:selectList>
                </apex:outputPanel>
             </div>
              <div class="col-xs-2" style="text-align: center;">
                   <div class="circle"> > </div>
                </div>

                <div class="col-xs-5" style="text-align: left;">
                  <apex:outputPanel id="genabilityPR">
                        <apex:selectList style="width:100%;" styleClass="selectinline" id="prorate" size="1" value="{!electricrateproposedselected}" disabled="{!!ratesEdited}" multiselect="false">
                            <apex:selectOptions value="{!ElectricPropsedRate}"/>
                        </apex:selectList>
                    </apex:outputPanel>
                </div>
            </div>
  • 1
    Please edit your question to include code. – sfdcfox Mar 29 '17 at 19:34
  • 1
    Is this on a visualforce page? If so, you should edit your question to include your visualforce code, or a relevant snippet others can use to replicate your issue. – battery.cord Mar 29 '17 at 19:34
  • Yes. It's a VF page. – amidstCloud Mar 29 '17 at 19:35

Your Answer

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

Browse other questions tagged or ask your own question.