Adding image/logo on selection screen

How can I add image or logo on my selection - screen??

Hi,
in AT-SELECTION-OUTPUT EVENT put these codes:
  data: lv_docking           type ref to cl_gui_docking_container,
        lv_picture_control_1 type ref to cl_gui_picture,
        lv_url(256)          type c ,
        li_query_table       type w3query occurs 1 with header line,
        li_html_table        type w3html occurs 1,
        lv_return_code       type w3param-ret_code,
        lv_content_type      type w3param-cont_type,
        lv_content_length    type w3param-cont_len,
        li_pic_data          type w3mime occurs 0,
        lv_pic_size          type i.
  refresh :li_query_table ,li_html_table , li_pic_data.
  clear   :
  lv_url,
  lv_return_code,
  lv_pic_size,
  lv_picture_control_1,
  lv_docking,
  lv_content_type,
  lv_content_length.
  create object lv_picture_control_1
    exporting
      parent = lv_docking.
  check sy-subrc = 0.
  call method lv_picture_control_1->set_3d_border
    exporting
      border = 5.
  call method lv_picture_control_1->set_display_mode
    exporting
      display_mode = cl_gui_picture=>display_mode_stretch.
  call method lv_picture_control_1->set_position
    exporting
      height = 75
      left   = 1200
      top    = 250
      width  = 250.
  if lv_url is initial.
    refresh li_query_table.
    li_query_table-name  = '_OBJECT_ID'.
*IMAGE UPLOADED IN SWO0
    li_query_table-value = 'ZLOGO'.
    append li_query_table.
    call function 'WWW_GET_MIME_OBJECT'
      tables
        query_string        = li_query_table
        html                = li_html_table
        mime                = li_pic_data
      changing
        return_code         = lv_return_code
        content_type        = lv_content_type
        content_length      = lv_content_length
      exceptions
        object_not_found    = 1
        parameter_not_found = 2
        others              = 3.
    if sy-subrc <> 0.
     MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
             WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    endif.
    call function 'DP_CREATE_URL'
      exporting
        type     = 'image'
        subtype  = cndp_sap_tab_unknown
        size     = lv_pic_size
        lifetime = cndp_lifetime_transaction
      tables
        data     = li_pic_data
      changing
        url      = lv_url
      exceptions
        others   = 1.
  endif.
  call method lv_picture_control_1->load_picture_from_url
    exporting
      url = lv_url.

Similar Messages

  • Show Picture/logo on Selection Screen from OAER

    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:
    ABAP - Display LOGO On Selection Screen.&lt;/title&gt;&lt;title&gt;Learn ABAP Programming With Examples And Sample Progr…
    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

    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

  • Logo in selection screen

    hi experts ,
    can we add logo in selection screen .
      if yes the how it can be possible .
    Thanks And Regards .
      Priyank

    To create a logo u have to remember one thing is u have to upload that logo through OAER or SE78
    for uploading logo in OAER
    Enter class name as PICTURES
    Class type as OT
    Object key the name of ur logo want to upload
    then press F8 or execute
    Then it will automatically creates a folder for ur LOGO and upload ur logo in that folder
    After that In the left side bottom of the page u can c the following options
    1)Detail
    2)Document Info
    3)Keywords
    4)Create
    goto Detail in which u can find the Object Id
    which u have to paste in the function module of this program
    Check this program1
    REPORT  YMS_LOGOSEL.
    *REPORT  ZREPORT_LOGO.
    DATA:
    docking TYPE REF TO cl_gui_docking_container,
    picture_control_1 TYPE REF TO cl_gui_picture,
    url(256) TYPE c .
    DATA : sum(4) , num1(4) , num2(4).
    PARAMETERS: p_dummy(4) DEFAULT '4' .
    PARAMETERS: p_dummy1(4) DEFAULT '5' .
    AT SELECTION-SCREEN OUTPUT.
    PERFORM show_pic.
    START-OF-SELECTION.
    num1 = p_dummy.
    num2 = p_dummy1.
    sum = num1 + num2.
    WRITE : / sum.
    *& Form show_pic
    FORM show_pic.
    DATA: repid LIKE sy-repid.
    repid = sy-repid.
    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 = 100
    left = 500
    top = 10
    width = 300.
    CALL METHOD picture_control_1->load_picture_from_url
    EXPORTING
    url = 'c:/pic.bmp'.
    IF sy-subrc NE 0.
    ENDIF.
    ENDFORM. "show_pic

  • Adding Logo In selection screen

    Hi,
    I would like to add  company logo in the selection screen of a web report. Please let me know how to do this.
    Regards,

    Hi Bill,
    Customizing for the variable acreen in the web reports has not been provided for by SAP. It will be possible by modification. You can refer to these 2 posts by an SAP Developer (Heike Guder):
    Web Template: Customizing Variable Screen
    BeX Web App - Variable Screen
    Hope this helps...

  • How to Place a LOGO on Selection screen & Output list -OO ALV

    Hi,
    I was just wondering can we place a logo on standard Selection screen 1000?
    And also on the Output list . I am using OO ABAP for my ALV.
    regards
    Praveen

    Hi,
    You cannot place a logo in your selection-screen.
    But yes, you can place logos in your OO ALV.
    data:       ws_c_logo      TYPE REF TO cl_dd_area.
                                                      "Instance for the logo
    Split your document container for logo
       CALL METHOD wcl_docum->vertical_split
               EXPORTING split_area  = wcl_docum
                         split_width = '70%'
               IMPORTING right_area  = ws_c_logo.
    then,
      CALL METHOD ws_c_logo->add_picture
              EXPORTING picture_id = c_logo.
    where:      c_logo TYPE sdydo_key VALUE 'CC0040' .  "logo for co.code 0040
    The image should be stored in your business document. You may use BDS_OBJECT_SAVE or BDS_BUSINESSDOCUMENT_CREATEF to store the image in the business document server and then retrieve in your ALV.
    Regards
    Subramanian

  • Adding check box in selection screen

    Hi all,
    I have to add a check box to the previous report, I need to fetch the data based on the checkbox. Please tell me how to proceed further with flag set.
    Thanx and Regards,
    Line.

    Hi..
    1) do u want this? if checkbox is not checked then no data is read from database and if checked then only data wil be fetched -
    tables pa0001.
    parameters p_check as checkbox.
    data: begin of itab occurs 0.
    include structure pa0001.
    data end of itab.
    start-of-selection.
    if p_check = 'X'.
    perform read_data.
    endif.
    if itab[] is not initial.
    loop at itab.
    write:/ itab-pernr.
    endloop.
    else.
    write: 'No data fetched from database,may be u need to check the Checkbox'.
    endif.
    *&      Form  read_data
          text
    -->  p1        text
    <--  p2        text
    FORM read_data .
    select * from pa0001 into table itab up to 20 rows.
    ENDFORM.                    " read_data
    2) Adding fields based on Chekbox -
    parameters: p_check AS CHECKBOX  MODIF ID ABC USER-COMMAND CH.
    parameters: p_pernr like pa0001-pernr modif ID ABD,
                P_DATE LIKE PA0001-BEGDA MODIF ID ABD.
    Check sy-ucomm = 'CH'.
    AT SELECTION-SCREEN OUTPUT.
    loop at screen.
    if p_CHECK = 'X'.
       if screen-group1 = 'ABD'.
          SCREEN-ACTIVE = '1'.
          MODIFY SCREEN.
       ENDIF.
    ELSE.
      if screen-group1 = 'ABD'.
         SCREEN-ACTIVE = '0'.
         MODIFY SCREEN.
         ENDIF.
    ENDIF.
    ENDLOOP.

  • Adding new modules to Selection-screen

    Hi everyone,
    I created 3 selection-screens for my report, but I needed to control better their jump between screens, so I added PAI modules on each screen.
    The thing is that when I make a change on one of the screens the calling of the module disapears, so I just kept on placing the calls and avoided the change in the screens.
    No the problem is, when I transported my report to the quality system, everything was fine, with my modules in my code. Now I transported a change and in the quality system, the calls where lost.
    Any ideas how to transport everything?!
    Thanks

    You must not modify the screen (add PAI or PBO) with a program type 1 (report).
    If you want to modify screen, you change your program type module pool and create the screens.
    Salu2.

  • Added field to dynamic selection screen does not work in FBL5N

    hi,
    we have added KNA1-KATR5 to the selection screen of FBL5N by using logical database DDF using "view CUS" but it does not work.
    Our system is 6.0
    is there any OSS note or program that we should add?
    many thx.

    Refer This:
    Additional field selections in FB03

  • Adding layout variant to selection screen

    Hi all,
             Currently I am working on report program, where I have to allow user to select his own output pattern. i.e layout variant is to be added to selection screen. The report uses object oriented ALV for display purpose. [set_table_for_first_display]
    I made following steps,
    1.     Declared one parameter of type disvariant.
    2.     At selection-screen on value-request I called function REUSE_ALV_VARIANT_F4.
    3.     Passed internal table to method set_table_for_first_display.
    Now I am able to create save new variant, on selection screen I can select the variant that I have created, but output shows the all the fields though
    Only few are selected. Please tell me any modification so as to reflect the changes in output.
    I  am searching for a function which maintains fieldcat according to user defined variant.
    Regards,
    Nilesh kulkarni.

    U have to use REUSE_ALV_VARIANT_EXISTENCE inorder to use the layout u have selected
    After ur code of REUSE_ALV_VARIANT_F4.
    try this way
    AT SELECTION-SCREEN.
       PERFORM PAI_OF_SELECTION_SCREEN.
    G_REPID = SY-REPID.
    G_SAVE = 'A'.
    FORM PAI_OF_SELECTION_SCREEN .
      IF NOT P_LAYOUT IS INITIAL.
        MOVE G_VARIANT TO GX_VARIANT.
        MOVE P_LAYOUT TO GX_VARIANT-VARIANT.
        CALL FUNCTION 'REUSE_ALV_VARIANT_EXISTENCE'
             EXPORTING
                  I_SAVE     = G_SAVE
             CHANGING
                  CS_VARIANT = GX_VARIANT.
        G_VARIANT = GX_VARIANT.
      ELSE.
        PERFORM VARIANT_INIT.
      ENDIF.
    ENDFORM.                    " PAI_OF_SELECTION_SCREEN
    FORM variant_init .
      CLEAR G_VARIANT.
      G_VARIANT-REPORT = G_REPID.
    ENDFORM.                    " variant_init
    Then when u call ALV for display, pass ur display variant, in this case  = g_variant
    Reward if useful
    Cheers
    ~Arun
    Message was edited by:
            Arun Shekhar

  • Adding fields to vendor selection screen

    Hi ,
    While creating a shopping cart from SRM portal, i need to select a  vendor. For vendor selection screen, i want to add two additional fields:  1)Sort Term 1:  ADDR1_DATA-SORT1 2)Order Currency:  LFM1-WAERS
    I want to know:if this can be possible by doing any SRM config in SPRO in SRM or is it a development work in which fields would be added to structure.
    Please reply asap and also the procedure to do that.
    Regards,
    Bis

    Hi.
    Have you read SAP Note 672960? This describes how to add customer defined fields to the shopping cart, therefore also visible during the SC creation process. You would probably also need to implement the BBP_DOC_CHANGE_BADI to fill in the requested data in your new fields.
    DM

  • Adding fields to the selection screen of IW38

    We have added some fields to the CI_AUFK include, they have also been added to the RIHAUFK_LIST structure. Currently the new fields appear in the ALV when the report is run.
    What I need to do is add them to the selection screen.
    Has anyone done this? I have been looking for a user exit etc, no luck.
    Thanks, Mike

    Why not use the new enhancement framework?
    Goto the main program in SE38 and click on the Enhance button - spiral icon (Shift+F4) and try to add new selections at the appropriate by implementing the appropriate enhancement.
    I am sure you can achieve it using enhancement spots.
    cheers,
    Aabhas

  • Adding image for the selected Tree leaf???

    Hi All,
             I am working with flex tree component in which i have to add
    an arrow image for the  selected leaf node. I tried to do this using itemclick event
    but cant make it. can you help me out in doing this???
    Note: I have written custom Tree and TreeItemRenderer...
    -Sundar

    Thanks for ur reply Grizzzzzzzzz,
                                                    is there a way to identify the selected leaf from within MyTreeItemRenderer(Extends TreeItemRenderer)?
                                                   If this is possible,i can add the image to the selected leaf of the tree.
    Right now i am assigning images to all the leaf nodes of the tree as follows:
    public  
    class MyTreeItemRenderer extends TreeItemRenderer
    * Override to draw a line in case current item is a leaf.
     override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):
    void{ 
    // Call super method 
    super.updateDisplayList(unscaledWidth, unscaledHeight);
    if(super.data){
    if(TreeListData(super.listData).hasChildren){
    // logic for parent node comes here
    else{ 
    //Adding leaf Image
    //Logic to add images to leaf 
    myImage.source = leafImage;
    myImage.x =
    super.label.x;
    //The above code adds images to all leaf nodes. CAN I ADD THIS IMAGE ONLY TO THE SELECTED LEAF NODE???
    //HOW TO FIND THE SELECTED LEAF NODE FROM HERE??? SO THAT SELECTED LEAF WILL BE ADDED WITH THE IMAGE???
    //The above code adds images to all leaf nodes. CAN I ADD THIS IMAGE ONLY TO THE SELECTED LEAF NODE???
    //HOW TO FIND THE SELECTED LEAF NODE FROM HERE??? SO THAT SELECTED LEAF WILL BE ADDED WITH THE IMAGE???
    THANKS,
    SUNDAR 

  • Difficulty in adding new parameter in selection screen of GR55 report

    Hi Gurus,
    I have a requirement to add an extra field in Cost center:Act/Plan/Comm CC Cur report.This is otherwise a Z report in report painter with 0% code (T-code : GR55-> Report group->Report).But,when we go to technical information of this report,it has four standard sap programs,which contains code for this selection screen.It does not even have a modification scope.
    Selection screen of this report contains following parameters:
    Selection values:
    Controlling Ar
    Fiscal Year
    From Period
    To Period
    Plan Version
    Selection Groups:
    Cost Center Group
    Or value(s)
    Cost Element Group
    Or value(s)
    My requirement is to add one more parameter : Purchase oeder in new block:
    Is there any way to achieve it.
    Note: Copying the standard progs into custom prog is not working,i already tried that.
    Please let me know your suggestions,if any one of you came across such requirement before.it is very impoertant for me.
    Thanks in advance,
    Meenakshi

    Hi  meenakshi239,
    you can always use implicit enhancement spots.
    Regards,
    Clemens

  • Adding field in the selection-screen of a zprogram

    hi gurus,
    i have to add field in the selection-screen of oppurtunities. in database i have a field salesvalues, some of oppurtunity guids have this field value. first i need to add in selection-screen in this alv report. and fetch the data from ztable into required field . if the input fields of the salesvalues field id filled, then filter the global  guids(from global table which had the guid values already) with this guids related to salesvalues. and if one single guid mathes to 2 values of salesvalues then concatenate 2 values with comma and display in single field. if select-options are blank then fetch all opportunity guids which have salesvalues. pls give solution.

    Hi Srini,
    Thanks for your Reply
    I have kept 01 against the field BSEG-AUGDT and selected the preselect check box also.
    But still that field is not visible in the dynamic selection screen.
    Thanks
    Ajay.D

  • Adding customer field to selection screen of RFKORD11 - Customer  Statement Printing Program:

    Hello,
    We are required to add an important customer field to selection screen of customer
    statement printing program: RFKORD11 for our South African branch.
    Please advise us regarding this matter,
    is there a proper user-exit or a repair is needed?
    Kind Regards.

    Enhancement
    text
    F050S001
    FIDCMT, FIDCC1,
      FIDCC2: Edit user-defined IDoc segment
    F050S002
    FIDCC1: Change
      IDoc/do not send
    F050S003
    FIDCC2: Change
      IDoc/do not send
    F050S004
    FIDCMT, FIDCC1,
      FIDCC2: Change outbound IDoc/do not send
    F050S005
    FIDCMT, FIDCC1,
      FIDCC2 Inbound IDoc: Change FI document
    F050S006
    FI Outgoing IDoc:
      Reset Clearing in FI Document
    F050S007
    FIDCCH Outbound:
      Influence on IDoc for Document Change
    F180A001
    Balance Sheet
      Adjustment
    FARC0001
    Enhancements within
      archiving (FI)
    FARC0002
    Additional Checks for
      Archiving MM Vendor Master Data
    FEDI0001
    Function exits for
      EDI in FI
    FICT0001
    Exits for
      inter-company transactions
    RFAVIS01
    Customer Exit for
      Changing Payment Advice Segment Text
    RFBVX001
    Enhancement for bank
      directory transfer (Austria)
    RFEPOS00
    Line item display:
      Checking of selection conditions
    SAPLBANK
    User exit: Bank data
    SAPLF040
    WF: Preliminary
      posting (authorized for release)
    SAPLF051
    Workflow for FI
      (pre-capture, release for payment)
    SAPLFCPD
    One-time account data
      or different payee in booking
    SAPLSSRV
    User exit: Bank
      account numbers
    RFKORIEX
    Automatic
      correspondence
    please check which one  is better .

Maybe you are looking for