Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8623

Re: Refresh, Update Dynpro PBO Picture

$
0
0

Hi,

 

although I'm not sure if this will help you I've copied a code snippet from a program where a picture is changed dynamically because of a double click in a tree control.

 

...

 

   DATA:  g_picture_control TYPE REF TO cl_gui_picture,
              g_container TYPE REF TO cl_gui_custom_container.

 

...

 

    METHOD  handle_item_double_click.
    " this method handles the item double click event of the tree
    " control instance

    DATA: url TYPE cndp_url.

    IF node_key = 'XXX' OR node_key = 'YYY'.

      IF g_picture_control IS INITIAL.

*       Create controls
        CREATE OBJECT g_container
          EXPORTING container_name = 'PICTURE_CONTROL'.

        CREATE OBJECT g_picture_control EXPORTING parent = g_container.

*       Set the display mode to 'normal' (0)
        CALL METHOD g_picture_control->set_display_mode
          EXPORTING
            display_mode = cl_gui_picture=>display_mode_normal.

*       Set 3D Border
        CALL METHOD g_picture_control->set_3d_border
          EXPORTING
            border = 0.

      ENDIF.

      CASE node_key.
       

       WHEN 'XXX'.

          url = 'http://......p1jpg'



        WHEN 'YYY'.

          url = 'http://......p2jpg'.

      ENDCASE.

*     Load the picture by using the URL

      CALL METHOD g_picture_control->load_picture_from_url_async
        EXPORTING
          url = url.

    ENDIF.

  ENDMETHOD.                    "HANDLE_ITEM_DOUBLE_CLICK


Viewing all articles
Browse latest Browse all 8623

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>