cancel
Showing results for 
Search instead for 
Did you mean: 

Call View Method from Componentcontroller?

Former Member
0 Kudos

Hello @all,

how can i call a view method from the componentcontroller?

Regards

Chrisp

Accepted Solutions (1)

Accepted Solutions (1)

p330068
Active Contributor
0 Kudos

Hi Chrisp,

Which method of the view you want to call from component controller. It is always better to create methods in component controller or custom controller to use in different views that inhance perfomance for views.

Hope it helps

Regards

Arun

Former Member
0 Kudos

hi,

i have many views in one component. In one view i want to call a method from another view. How can i do this?

Regards

Former Member
0 Kudos

Hi Christopher,

Views are private. All the declaration and the method creation will be particular to that view.

Create all your methods in Component Controller( which is public and will be available everywhere ) and use them in the Views.

Answers (2)

Answers (2)

ChrisPaine
Active Contributor
0 Kudos

Hello,

Create an event handler in your view for an event of your controller component.

raise this event in your component - then your view should pick up the event, which could handle calling your view method

Cheers,

Chris

Former Member
0 Kudos

View methods\attributes\ context data are private in nature, you can't call them anywhere else except view.

Create you method in CompController ( mark it public ) and then you can use it across all views present in comp controller.

regards

manas dua