on 06-03-2017 10:18 PM
Hi Gurus,
My current component is called from multiple component and I have to do validation based on the calling component.But how to read the calling component(Not application)
Below is my finding
lo_cmp_apix TYPE REF TO if_wd_component,
lo_window_managerx TYPE REF TO if_wd_window_manager,
lo_cmp_apix = wd_comp_controller->wd_get_api( ).
lo_window_managerx = lo_cmp_apix->get_window_manager( ).
In the object Lo_window_manger there is a parent details but how to read it???
Kindly help me to rectify this issue.
Thanks in advance.
Jamal
There is not really a concept as "called from" in the same way as with ABAP, there is no call hierarchy.
A safer alternative would be to pass in a 'mode' parameter or send any needed data across. This means you're not creating as many dependencies.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
OK, it's important to make this clear. "Call" can be a plug-navigation, FPM GAF, Usage, iView, or other setup.
Navigating via visual elements (View -> Window -> ?) is not the WDA way, for components usages you should use interfaces. These are in part created automatically for you, you just need to expose any additional elements (methods etc.) that other controllers can use.
From the info you have given, a few option are available:
- Create a standalone component that is common to both using and used components
- Pass a reference to the using controller in during instantiation of the used controller
- Create a reverse component usage and expose the using controller's methods
The third option is the most robust, ideally via a standalone interface controller to ensure that all using controllers implement the same interface.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.