Use the HTMLB library to display SAP data in HTML
Please send me the sample code to display SAP data from an internal table to HTML format, from an HTML screen to view/execute the trans code or query on SAP data.
For easy design, you can use the very powerful HTMLB library, a number of macros that render into plain HTML and Javascript. To see what is possible to create a BSP application and a page, browse the possible HTMLB tags in Tag Browser->BSP Extensions->Transportable->HMLB
A very simple example may look like this.
<html> <head> <% data: itab type table of sflight. %> <% field-symbols: <row> like line of itab. %> <% select * from sflight into table itab. %> </head> <body> <table> <% loop at itab assign <row>. %> <tr> <td><%= <row>-carrid %></td> <td><%= <row>-connid %></td> </tr> <% endloop. %> </table> </body> </html>
If you want to call transaction codes via HTML you need to activate the ITS.