You need to sign in to do that
Don't have an account?
Suresh Raghuram
Populate picklist from the custom object to the Visualforce page
Hi
I am new to the Visualforce
I want to populate a picklist called Security_Question__C which is a field on the MyContact__c custom object.
I tried different way , but it is not working could any body suggest me a solutution with code.
check the value in the debug log. Let me know if this doesnt work.
All Answers
Try this. Let me know if it doesnt work.
<apex:page controller="SinglepicklistforMyContact" >
<apex:form >
<apex:selectList size="1" value="{!SelectValue}"></apex:selectList>
<apex:selectOption value="{!statusOptions}"></apex:selectOption>
</apex:form>
</apex:page>
In place of {!SlectValue} i used MyContact__c.Security_Question__c
but it is showing the error as invalid identifier MyContact__C
try this.
It is not giving any errors but result is empty picklist
check the value in the debug log. Let me know if this doesnt work.
Thank you Naidu it worked and could you suggest some programs to learn visual force and apex in , like some examples and scenarios for triggers and vf pages from your real time scenarios.
Once again thank you very much for the help.
On the page where you call the controller:
Thank you for this!