ABAP 如何显示图片

见标准示例程序: SAP_PICTURE_DEMO

 

程序运行效果:

 

核心代码:

 

      data picture_control_1 type ref to cl_gui_picture .

     data container_1 type ref to cl_gui_custom_container.

   

     create object container_1
      exporting container_name = 'PICTURE_CONTROL_1'.

 

         CREATE OBJECT PICTURE_CONTROL_1 exporting parent = container_1.

 

     CALL METHOD PICTURE_CONTROL_1->LOAD_PICTURE_FROM_URL
           exporting url = url
           importing result = return.
      call method cl_gui_cfw=>flush.
      if return = 0.
        url = text-000.
      endif.

 

你可能感兴趣的:(SAP,ABAP一般)