on 06-08-2012 8:19 AM
Hi,
in my OVP two content areas exists (first is main, second is edit page). If I navigate from first to second method GET_CURRENT_CONTENT_AREA of IF_FPM_CNR_OVP in get_data of edit page returns values from main, not from current (edit) page. So the alternative coding is not good, get all content areas. loop and set if edit page is running.
Sys 7.0 EHP 2
Can anyone help?
Best regards.
Hello Stefan,
the method returns the current content area (which is the main page in your case) until the FPM event that triggers the navigation has been processed successfully. In the floorplan component (e.g. FPM_OVP_COMPONENT) the first time point at which the FPM runtime can state that the event was successfully processed is method MODIFY_VIEW_ASSEMBLY. In this method the content area will be switched to the target content area if the navigation event has been processed successfully. The GET_DATA method of an GUIBB would be too early since the navigation event could still be canceled in the method AFTER_PROCESS_EVENT of an Application Controller (interface IF_FPM_APP_CONTROLLER).
Best regards,
Jens
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
To change the edit page dynamically.
OVP main page includes SEARCH and LIST UIBB. After clicking a row of LIST UIBB the edit page is calling. In dependense of mode the toolbar includes other buttons and the title is an other. This coding is triggered in GET_DATA of FORM_UIBB of edit page.
I change this with the restricted method, but this method has an parameter page id.
OK, but this has nothing to do with the interface IF_FPM_FLOORPLAN_COMP. This interface is required for floorplan components and can only be used by the FPM development team.
As I mentioned above the new target content area will be set by the FPM floorplan component after method GET_DATA of the GUIBBs has been called. The reason is that the currently processed FPM event can still be canceled after method GET_DATA in method AFTER_PROCESS_EVENT of an Application Controller (interface IF_FPM_APP_CONTROLLER). If you want to modify the toolbar buttons or the title you have to pass the page ID that you have specified in the OVP configuration to the respective OVP API methods.
This is what I do.
On edit page there are 3 GUIBBs, each GUIBB is "equal". Which GUIBB should trigger the title change? In moment my first GUIBB (Form includes Header Data) sets title in GET_DATA method controlled by an init flag (method INIT is called only one time ).
Alternatively OVERRIDE Method of component controller sets the title. Advantage: one common coding place, disadvantage separation of coding and source event.
I have those problems verry often. Example: Main page has a button CREATE in "main"-toolbar and list has a button EDIT in list toolbar. EDIT is triggered by PROCESS_EVENT, but which GUIBB should trigger CREATE? Why INIT of GUIBB is only running one time? As result GET_DATA has init conding...and so on.
Since a static configured page title for the edit page is apparently not sufficient in your case I guess that, depending on certain criteria, you can have different page titles for that edit page. And the question is which GUIBB feeder should adapt the title, right?
This is up to your application. You could have one main GUIBB that does the title change. However, if this GUIBB is hidden via the OVP personalization dialog it will not work anymore. Or you implement the logic in all the GUIBB on the edit page... or you implement the logic in an external singleton class that can be accessed by all your GUIBBs... or you implement the logic in an AppCC (as you have already mentioned). There are many possibilities as you can see.
If you are on NW 7.31 there is also the elegant possibility to use a "Technical UIBB". This is a hidden UIBB/ GUIBB on the page that will participate on the FPM event loop but which does never appear on the UI. In order to specify a UIBB as "technical" you have to set the property 'Hidden' of the UIBB in the OVP configuration to the appropriate value 'Hidden but Processed in Event Loop (Technical)'.
In IF_FPM_OVP_CONF_EXIT~OVERRIDE_EVENT_OVP method
io_ovp->get_content_areas(
IMPORTING
et_content_area = lt_content_area ).
READ TABLE lt_content_area INTO ls_content_area WITH KEY id = 'PAGE_2'.
IF sy-subrc EQ 0.
CONCATENATE ls_content_area-title 'xyz_123' INTO ls_content_area-title SEPARATED BY ' - '.
TRY.
mo_ovp->change_content_area( is_content_area = ls_content_area ).
CATCH cx_fpm_floorplan.
ENDTRY.
ENDIF.
this works, you can change the title of any page
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.