You need to sign in to do that
Don't have an account?
Marcelo Agostinho
VF Fields to Apex Class Parameters! How can i do it?
Hello guys! Im having some problems trying to find how can i pass a value from a field for an Apex Class parameter
For exemple
My simple VF Page.
<apex:page controller="ProcessDataLoad"> <apex:form > <p> Actual Date (mm/aaaa)<apex:inputText id="actualDate"/> </p> <p> Month Quantity<apex:inputText id="qtdMonth"/> </p> <apex:commandButton value="Test"/> </apex:form> </apex:page>
And now i want to now how can i get these value in my Apex class when i click on commandButton?
Thanks for all!
Marcelo Agostinho
Hi,
You can use the <apex:param> tag for sending the parameters from page to apex class.
For more information on this use the component reference from Visualforce page.
Thanks,
Kodisana
Sorry i read about <apex:param> but i dont understand how can i get the value from my inputField and set my apex:param tag value!
Hi,
The variable that will be used in VF page should be declared in Controller class.
What is this {get; set;} after. parameter declaration ?
Very thanks for all the help!
These are the getters and setters as per Apex documentation.
You can find more info on that in Apex documentation.