Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Capturing WD_EVENT from SAP-GUI

Hi gurus,

I've developed an application that works in the browser, separately of the R/3 system.

Now I want embedd it into a control (no problem), and capture some events that user can do. For this reason, I open the wd application with a cl_gui_wdr_viewer, and I've defined an event handler:

CREATE OBJECT wdr_html_viewer

EXPORTING

parent = wdp_html_container.

CREATE OBJECT wdr_inplace_handler.

SET HANDLER wdr_inplace_handler->on_wd_event

FOR wdr_html_viewer.

CLASS cl_wdr_inplace_handler DEFINITION.

PUBLIC SECTION.

METHODS: on_wd_event

FOR EVENT wd_event OF cl_gui_wdr_viewer

IMPORTING action parameters. "#EC NEEDED

ENDCLASS. "cl_wdr_inplace_handler DEFINITION

CLASS cl_wdr_inplace_handler IMPLEMENTATION.

METHOD on_wd_event.

CASE action.

WHEN 'WDR_CLOSE'.

PERFORM leave_wdr_html_viewer.

LEAVE TO SCREEN 0.

WHEN 'WDR_START_TRANSACTION'.

(...)

ENDMETHOD. "on_wd_event

ENDCLASS. "cl_wdr_inplace

But I don't understand what means this ACTION of the case... an action in the main view? But WDR_START_TRANSACTION' is too long...

Thanks inadvance...

Alejandra Fernández

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question