You need to sign in to do that
Don't have an account?

how i can get selected id in selectlist
how i can get selected id in selectlist? I need to save a new object based on this value
value don't help me
<apex:pageBlockSection > Select a doctor: <apex:selectList size="1" value="{!selectedDoctor}"> <apex:selectOptions value="{!doctorSelectOptionList}"/> <apex:actionSupport event="onchange" action="console.log('{!selectedPatient}')" reRender="app_list1, app_list2, app_list3"/> </apex:selectList> </apex:pageBlockSection>
value don't help me
You need to have getter and setter methods in the controller class to get the selected option. You can check the below implementations in the below links:
>> https://developer.salesforce.com/docs/atlas.en-us.pages.meta/pages/pages_compref_selectList.htm
>> https://developer.salesforce.com/forums/?id=9060G0000005S9CQAU
Let me know if it helps you and close your query by marking it as the best answer so that it can help others in the future.
Thanks.