You need to sign in to do that
Don't have an account?
Pooja GL
Pass value selected on VF page on to an Apex Class that is not its Controller
Hi All,
I have a requirement where I have to use the value selected on the VF page in a different class other than its controller.
Is this do-able?
Please let me know if anyone has any information regarding this.
Thanks,
Pooja
I have a requirement where I have to use the value selected on the VF page in a different class other than its controller.
Is this do-able?
Please let me know if anyone has any information regarding this.
Thanks,
Pooja
In this scenario, you can make that class as an extension for you Visualforce Page.
You can have as many extensions as you need.
You can use extensions attribute of <apex:page> component for referring to any extensions you need. Refer below simple example from the documentation and understand how to bind the extension with the page and the constructor of the extension.
Please refer below link for more information on extensions.
https://developer.salesforce.com/docs/atlas.en-us.pages.meta/pages/pages_controller_extension.htm
Hope this helps you!
Please accept my solution as Best Answer if my reply was helpful. It will make it available for other as the proper solution. If you felt I went above and beyond, you can give me kudos.
Thanks and Regards
Sandhya