In my Web Dynpro: Running Web Dynpro Applications over SAPGUI I showed how to access Web Dynpro Applications via SAPGUI using the function WDY_EXECUTE_IN_PLACE.
In this I will do the same application but using the the class CL_GUI_HTML_VIEWER.
Creating the program
Go to the Object Navigator (SE80) and create a new program.
Now in the created program, add the following include programs:
GUI status and title
Create a GUI status like follows:
And a GUI title:
Global declarations and variables
Add the following code to the MZWDA_HTMLTOP include:
Creating the screen
Now create a screen:
Screen elements attributes
- Text Field:
- Input Output Field:
- Custom Control:
Screen element list
Screen flow logic
The screen flow logic is:
PBO modules logic
PAI module logic
Include MZWDA_HTMLF01 logic
Now it’s necessary to activate all objects and create a transaction like follows:
This blog was based on the SAP program RSDEMO_HTML_VIEWER and I got some references in the blog from Thomas Jung – Updated!: Calling a BSP application from a SAPGui Transaction.
And you can get more information about the class CL_GUI_HTML_VIEWER in the SAP Help Documentation.