06-18-2014 7:37 AM
HI everybody,
I uploaded a LOGO via TA OAER.
It works fine, when I Use call function 'REUSE_ALV_GRID_DISPLAY'
But now I want wot display the logo on the selection screen using the picture_control ( TYPE REF TO cl_gui_picture)
see:
Does anybody know how to read the picture uploaded in OAER for using it in the picture_control ( TYPE REF TO cl_gui_picture?
Thanks
Regards
Mario
06-18-2014 8:10 AM
Hi,
seems not to be possible:
http://www.erpgreat.com/fu002.htm
"Please note that the logo/background picture can only be displayed in ALV-based reports with an HTML header. Manually programmed reports such as business distribution plans are not based on the ALV. "
Thx, Regards
Mario
06-18-2014 8:10 AM
Hi,
seems not to be possible:
http://www.erpgreat.com/fu002.htm
"Please note that the logo/background picture can only be displayed in ALV-based reports with an HTML header. Manually programmed reports such as business distribution plans are not based on the ALV. "
Thx, Regards
Mario
06-18-2014 8:23 AM
Hi
This seems to work...
Not OAER .
This is based on article i saw around here somewhere....
DATA: ob_gui_docking_container_opn TYPE REF TO cl_gui_docking_container.
AT SELECTION-SCREEN OUTPUT .
PERFORM at_selection_screen_output .
*----------------------------------------------------------------------*
FORM at_selection_screen_output .
CHECK ob_gui_docking_container_opn IS INITIAL .
CREATE OBJECT ob_gui_docking_container_opn
EXPORTING
repid = sy-repid
dynnr = sy-dynnr
side = cl_gui_docking_container=>dock_at_bottom
ratio = 50.
DATA: ob_gui_picture TYPE REF TO cl_gui_picture .
CREATE OBJECT ob_gui_picture
EXPORTING
parent = ob_gui_docking_container_opn.
CALL METHOD ob_gui_picture->load_picture_from_url_async
EXPORTING
url = 'http://static.freepik.com/free-photo/smiley-face-clip-art_413110.jpg'
EXCEPTIONS
error = 1
OTHERS = 2.
IF sy-subrc NE 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL METHOD ob_gui_picture->set_display_mode
EXPORTING
display_mode = cl_gui_picture=>display_mode_fit_center.
ENDFORM . "at_selection_screen_output
Regards.
06-18-2014 8:32 AM
This is possible. please try following code:
PARAMETERS:c1 TYPE vbak-vbeln.
AT SELECTION-SCREEN OUTPUT.
PERFORM show_picture.
*&---------------------------------------------------------------------
**& Form show_picture
*&---------------------------------------------------------------------
FORM show_picture.
DATA picture_control_1 TYPE REF TO cl_gui_picture.
DATA :
docking TYPE REF TO cl_gui_custom_container,
logical_system LIKE bapibds01-log_system,
v_class LIKE bapibds01-classname,
v_type LIKE bapibds01-classtype,
v_client LIKE bapibds01-client,
v_objkey LIKE bapibds01-objkey,
url_lifetime LIKE bapibds01-uri_life,
standard_url_only LIKE sy-datar,
data_provider_url_only LIKE sy-datar,
web_applic_server_url_only LIKE sy-datar,
url_used_at TYPE sdok_fburl,
URIS TYPE TABLE OF BAPIURI WITH HEADER LINE,
url LIKE uris-uri.
v_objkey = 'FITP_SMILE'.
v_class = 'PICTURES'.
v_type = 'OT'.
v_client = sy-mandt.
CALL FUNCTION 'BDS_BUSINESSDOCUMENT_GET_URL'
EXPORTING
classname = v_class
classtype = v_type
client = v_client
object_key = v_objkey
TABLES
uris = uris.
* Find image
LOOP AT uris.
SEARCH uris-uri FOR 'smile.gif'.
IF sy-subrc = 0.
url = uris-uri.
EXIT.
ENDIF.
ENDLOOP.
BREAK-POINT.
CREATE OBJECT picture_control_1
EXPORTING
parent = docking.
CHECK sy-subrc = 0.
CALL METHOD picture_control_1->set_3d_border
EXPORTING
border = 5.
CALL METHOD picture_control_1->set_display_mode
EXPORTING
display_mode = cl_gui_picture=>display_mode_stretch.
CALL METHOD picture_control_1->set_position
EXPORTING
height = 55
left = 750
top = 08
width = 350.
CALL METHOD picture_control_1->load_picture_from_url
EXPORTING
url = url.
ENDFORM.
Regards