+ Start a Discussion

Call method in actionfunction in Visualforce component


I have component (without controller). I am using the component through the attribute of list and sring. I dont want to add the controller in it.
Now i want to call a method through actionfunction from the visualforce component. Please help me to how to do this.

John Pipkin 14John Pipkin 14

A Visualforce component with no controller cannot call a controller method. You can have the component call an actionFunction inside the visualforce page, though. 

Component controllers can also share instances of page controllers. See https://developer.salesforce.com/page/Controller_Component_Communication for how to set that up.

Hope that helps