Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

web browser

Former Member
0 Likes
448

dear all,

i want to know the tcode of the browser in abap

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
390

Hi,

Check sample web browser programs:

SAPHTML_DEMO1

SAPHTML_EVENTS_DEMO

RSDEMO_HTML_VIEWER

Best regards,

Prashant

2 REPLIES 2
Read only

Former Member
0 Likes
390

hi

i don't know the correct tcode but through objects we can do it.

check it out the below program.

in screen 9000.

1.put the custom control

2.give the name field is 'CONTAINER_HTML'.

DATA: html_control TYPE REF TO cl_gui_html_viewer,

my_container TYPE REF TO cl_gui_custom_container,

edurl(2048).

EDURL = 'WWW.SDN.SAP.COM'.

SET SCREEN 9000.

&----


*& Module STATUS_9000 OUTPUT

&----


  • text

----


MODULE status_9000 OUTPUT.

SET PF-STATUS 'MAIN'.

  • SET TITLEBAR 'xxx'.

IF my_container IS INITIAL.

CREATE OBJECT my_container

EXPORTING

container_name = 'CONTAINER_HTML'

EXCEPTIONS

OTHERS = 1.

ENDIF.

IF html_control IS INITIAL.

CREATE OBJECT html_control

EXPORTING

parent = my_container.

PERFORM load_home_page.

ENDIF.

ENDMODULE. " STATUS_9000 OUTPUT

&----


*& Module USER_COMMAND_9000 INPUT

&----


  • text

----


MODULE user_command_9000 INPUT.

CASE sy-ucomm.

WHEN 'BACK'.

LEAVE PROGRAM.

ENDCASE.

ENDMODULE. " USER_COMMAND_9000 INPUT

&----


*& Form load_home_page

&----


  • text

----


  • --> p1 text

  • <-- p2 text

----


FORM load_home_page .

DATA: doc_url(80).

  • CALL METHOD html_control->load_html_document

  • EXPORTING

  • document_id = 'HTMLCNTL_CNHTTST1_START'

  • IMPORTING

  • assigned_url = doc_url

  • EXCEPTIONS

  • OTHERS = 1.

*

  • IF sy-subrc EQ 0.

  • CALL METHOD html_control->show_url

  • EXPORTING

  • url = doc_url.

  • ENDIF.

CALL METHOD html_control->show_url

EXPORTING

url = EDURL

EXCEPTIONS

cnht_error_parameter = 1

OTHERS = 2.

IF sy-subrc GE 2.

RAISE cntl_error.

ENDIF.

ENDFORM. " load_home_page

i hope it will help for u.

if u not get it means please reply me ..

regards

baskaran

Message was edited by:

baskaran nagamanickam

Message was edited by:

baskaran nagamanickam

Read only

Former Member
0 Likes
391

Hi,

Check sample web browser programs:

SAPHTML_DEMO1

SAPHTML_EVENTS_DEMO

RSDEMO_HTML_VIEWER

Best regards,

Prashant