cancel
Showing results for 
Search instead for 
Did you mean: 

Regarding IF_FPM_WORK_PROTECTION interface

Former Member
0 Kudos

Dear Experts,

Im facing an issue with IF_FPM_WORK_PROTECTION interface.

The issue is ,i have 'Close' button in my two applications.

1) FPM_OIF_COMPONENT

2) FPM_OVP_COMPONENT.

I implemented IF_FPM_WORK_PROTECTION interface in both of the components.While clicking on Close button,I can get one pop-up for FPM_OIF_COMPONENT by setting ev_dirty flag as abap_true which can close the current window.

But the same is not working  on FPM_OVP_COMPONENT senario.i can able to get the pop-up,but on click of OK,the window is not getting close....

Can anyone suggest me how to open a popup on click of Clos button?....

Thanks

Katrice

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Dear Kiran,

I have done the same as per your sugesstion.On click of Close button,Im getting POP-UP window...But on click of OK button in POP-UP,the window is not getting closed.

Thanks

Katrice

Former Member
0 Kudos

Hi Katrice,

That's good your getting popup now you should close the popup on OK or CLOSE button

when you click any of these buttons FPM_CLOSE_DIALOG event is triggered in either GET_DATA

or PROCESS_EVENT method.

write this code in any one of the method.

lo_fpm is class reference of IF_FPM.

   CASE io_event->mv_event_id.

     WHEN 'FPM_CLOSE_DIALOG'.

    lo_fpm->raise_event_by_id( iv_event_id = cl_fpm_event=>gc_event_close ).

   ENDCASE.

Regards

Madhukiran.

Former Member
0 Kudos

Thanks Kiran,

Its working...

Katrice

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Katrice,

In FPM_OVP_COMPONENT what ever UIBB your configuring for example tree or form UIBB.

So for every uibb will have a extended interface for example IF_FPM_GUIBB_form_EXT   or IF_FPM_GUIBB_TREE_EXT in these interfaces you'll have a method NEEDS_CONFIRMATION you can write your code this method is for DATA LOSS where you can give a confirmation popup.

Implement this code in NEEDS_CONFIRMATION Method.

METHOD if_fpm_guibb_tree_ext~needs_confirmation.

   CLEAR eo_confirmation_request.

   CASE io_event->mv_event_id.

     WHEN 'FPM_CLOSE'. "

       IF flag_confirm = 'X' AND ( first_time = 'X' OR mv_confirmation = ' ' ).

         eo_confirmation_request = cl_fpm_confirmation_request=>go_data_loss.

       ENDIF.

   ENDCASE.

ENDMETHOD.

Regards

Madhukiran.

Former Member
0 Kudos

Dear Kiran,

From where do we get

flag_confirm = 'X' AND ( first_time = 'X' OR mv_confirmation = ' ' ) parameters?

Former Member
0 Kudos

Hi Katrice

These are my conditions which i have used in my code don't use this.

use this

METHOD if_fpm_guibb_tree_ext~needs_confirmation.

   CLEAR eo_confirmation_request.

   CASE io_event->mv_event_id.

     WHEN 'FPM_CLOSE'. "

         eo_confirmation_request = cl_fpm_confirmation_request=>go_data_loss.

   ENDCASE.

ENDMETHOD.

Former Member
0 Kudos

Dear Kiran,

I've done the same,But on click of Close button,the pop-up is getting triggered.But on click of OK button in pop-up,the application is not getting closed.

Thanks

Katrice