08-10-2012 7:31 AM
Hi,
i have a requirement to display the current time of the system in a field on the module pool screen.
once PBo is loading i am capturing the time and displaying,, but the requirement is like the time should not static it should be dynamically changing like stopwatch.
please advise whether it is possible or not .
08-10-2012 7:37 AM
08-10-2012 7:46 AM
Hi Mukesh,
IN ABAP screens, data is generally static and to refresh the screens contents Module pool generally require a event (Like enter or back event). I think there is one FM which can trigger such event which can be used to refresh the screen, but it will not be like a stop-watch..
- Harshad
08-10-2012 7:47 AM
Hi,
you can use class CL_GUI_TIMER to get it updated every n seconds.
The hurdle is that the screen is only updated by going thru the PBO - PAI cycle which requires user action.
A solution might be a small html-control inside your screen which contains only the time field.
Regards,
Dirk
08-10-2012 8:52 AM
CL_GUI_TIMER can solve the problem if in the method handling the on_finished event you use a cl_gui_cfw=>set_new_ok_code to raise a PAI/PBO cycle.
(Or ask user not to hide Windows taskbar...)
Regards,
Raymond
08-10-2012 8:57 AM
Can't set_new_ok_code confuse the user if he/she is just making some entry in a dynpro-field?
08-10-2012 9:02 AM
In fact I always used this option in display lists, not on input screen, just to display a "time of extraction" field, and never on an input screen.