cancel
Showing results for 
Search instead for 
Did you mean: 

Call view method of another view

uta_bchner
Explorer
0 Kudos

Hello everybody,

I wonder is it possible to call a view method from another view of the same component? If so, how?

I have a helper method configuring an ALV which I need to call from two different views. Moving the method to the component controller doesn't seem to work because the ALV usage is needed which is declared in the view only.

Any advice?

Thank you!

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

create a global variable at comp controller attributes tab of that ALV usage type.

When the reference of ALV usage is created in that view, assign this to global variable.

In the comp controller, move that method from that view to comp controller method, inside code check whether that variable is bound and then proceed with your logic.

uta_bchner
Explorer
0 Kudos

Thanks a lot for this idea! This will surely work.

Answers (0)