You need to sign in to do that
Don't have an account?
umesh1234
Checkbox option for drop down list in Visual force page?
Description:
I have one Visualforce page in that I want to display values in Dropdown list and I want to select Multiple values either using Check box or using Control .How to do this
I have one Visualforce page in that I want to display values in Dropdown list and I want to select Multiple values either using Check box or using Control .How to do this
There is an option named "multiselect". You can make it "true" for your purpose.
If you want to implement something custom then there are lots of jQuery components which you can utilize in your code.
Still you want something else please do let me know.
try bello code
-------------------------------------------------------------------
public with sharing class dynamicpicklist {
/**
* Webkul Software.
*
* @category Webkul
* @author Webkul
* @copyright Copyright (c) 2010-2016 Webkul Software Private Limited (https://webkul.com)
* @license https://store.webkul.com/license.html
*/
public dynamicpicklist()
{
}
public List<SelectOption> getdynamiclist() {
List<SelectOption> options = new List<SelectOption>();
options.add(new SelectOption('INDIA','INDIA'));
options.add(new SelectOption('US','US'));
options.add(new SelectOption('BRAZIL','BRAZIL'));
return options;
}
}
VF PAGE:
----------------------------------------------------------
<apex:page controller="dynamicpicklist">
<!--
/**
* Webkul Software.
*
* @category Webkul
* @author Webkul
* @copyright Copyright (c) 2010-2016 Webkul Software Private Limited (https://webkul.com)
* @license https://store.webkul.com/license.html
*/
-->
<apex:form >
<apex:selectList size="1">
<apex:selectOptions value="{!dynamiclist}"></apex:selectOptions>
</apex:selectList>
</apex:form>
</apex:page>
Hope below link will resolve your concern :-
http://www.codexworld.com/multi-select-dropdown-list-with-checkbox-jquery/
If doesn't then please let me know.