+ Start a Discussion
Vadivel MuruganVadivel Murugan 

Picklist value

How to get selected pick list values in apex
Mrunali GaonkarMrunali Gaonkar
HI,
You can use a get;set; to get selected picklist values in your apex.
Darshan Shah2Darshan Shah2
Hello Vadivel Murugan,

You can use below code:
Page:
<apex:selectList value="{!selectedCountry}" multiselect="false" size="1">
    <apex:selectOption itemValue="INDIA" itemLabel="India"/>
        <apex:selectOption itemValue="USA" itemLabel="USA"/>
        <apex:selectOption itemValue="United Kingdom" itemLabel="UK"/>
</apex:selectList>

Class:
public String selectedCountry {get;set;}

Warm Regards,
Darshan Shah
Sagar PareekSagar Pareek
https://www.salesforce.com/docs/developer/pages/Content/pages_compref_selectList.htm