PICTURE ON  A  MODULE POOL SCREEN

Hi All.
I have an issue in module pool program.
I designed a screen with number 100.
on this screen they want to put some picture...like some logo.
Is it possible to put the picture on this screen 0100.
Please can any body ,help me to solve this issue.
Thanks in advance,
Regards,
Eswar.

Hello,
You can use picture control to attach a picture to your screen.The sample code is below:
The custom container in the screen layout is named as 'CONTAINER'.
REPORT SAMPLE.
DATA: picture type ref to cl_gui_picture,
cont type ref to cl_gui_custom_container.
DATA: I_EVENTS TYPE CNTL_SIMPLE_EVENTS,
WA_EVENTS TYPE CNTL_SIMPLE_EVENT,
OK_CODE TYPE SY-UCOMM,
p_url type cndp_url.
Class click definition.
PUBLIC SECTION.
METHODS: click_handle for event picture_click of cl_gui_picture
importing MOUSE_POS_X MOUSE_POS_Y.
endclass.
DATA: click_variable type ref to click.
class click implementation.
method click_handle.
DATA: X_POS(5),Y_POS(5).
X_POS = MOUSE_POS_X.
Y_POS = MOUSE_POS_Y.
MESSAGE I000(OK) WITH 'Picture Click' X_POS Y_POS.
endmethod.
endclass.
START-OF-SELECTION.
call screen 100.
*& Module STATUS_0100 OUTPUT
text
MODULE STATUS_0100 OUTPUT.
SET PF-STATUS 'GUI'.
SET TITLEBAR 'xxx'.
if cont is initial.
CREATE OBJECT CONT
EXPORTING
CONTAINER_NAME = 'CONTAINER'.
CREATE OBJECT PICTURE
EXPORTING
LIFETIME =
SHELLSTYLE =
PARENT = cont
NAME =
EXCEPTIONS
ERROR = 1
others = 2
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
wa_events-EVENTID = picture->EVENTID_PICTURE_CLICK.
wa_events-APPL_EVENT = 'X'.
append wa_events to i_events.
CALL METHOD PICTURE->SET_REGISTERED_EVENTS
EXPORTING
EVENTS = i_events.
create object click_variable.
set handler click_variable->click_handle for picture.
CALL METHOD PICTURE->SET_3D_BORDER
EXPORTING
BORDER = 1.
CALL FUNCTION 'DP_PUBLISH_WWW_URL'
EXPORTING
OBJID = 'HTMLCNTL_TESTHTM2_SAP_AG'
LIFETIME = cndp_lifetime_transaction
IMPORTING
URL = p_url
IF SY-SUBRC = 0.
CALL METHOD PICTURE->LOAD_PICTURE_FROM_URL_ASYNC
EXPORTING
URL = p_url.
ENDIF.
endif.
ENDMODULE. " STATUS_0100 OUTPUT
*& Module USER_COMMAND_0100 INPUT
text
MODULE USER_COMMAND_0100 INPUT.
CASE OK_CODE.
WHEN 'BACK'.
LEAVE PROGRAM.
WHEN 'NORMAL'.
CALL METHOD PICTURE->SET_DISPLAY_MODE
EXPORTING
DISPLAY_MODE = CL_GUI_PICTURE=>DISPLAY_MODE_NORMAL.
WHEN 'FIT'.
CALL METHOD PICTURE->SET_DISPLAY_MODE
EXPORTING
DISPLAY_MODE = CL_GUI_PICTURE=>DISPLAY_MODE_FIT.
WHEN 'NORMAL_C'.
CALL METHOD PICTURE->SET_DISPLAY_MODE
EXPORTING
DISPLAY_MODE = CL_GUI_PICTURE=>DISPLAY_MODE_NORMAL_CENTER.
WHEN 'FIT_C'.
CALL METHOD PICTURE->SET_DISPLAY_MODE
EXPORTING
DISPLAY_MODE = CL_GUI_PICTURE=>DISPLAY_MODE_FIT_CENTER.
WHEN 'STRETCH'.
CALL METHOD PICTURE->SET_DISPLAY_MODE
EXPORTING
DISPLAY_MODE = CL_GUI_PICTURE=>DISPLAY_MODE_STRETCH.
WHEN 'CLEAR'.
CALL METHOD PICTURE->CLEAR_PICTURE.
WHEN SPACE.
CALL METHOD PICTURE->LOAD_PICTURE_FROM_URL
EXPORTING
URL = P_URL.
IMPORTING
RESULT = RETURN.
CALL METHOD CL_GUI_CFW=>FLUSH.
endcase.
endmodule.
Also check demo program:RSDEMO_PICTURE_CONTROL
<b>TO GET DIFFERENT PICTURES</b>:
(The following is <b>Judith Jessie Selvi's</b> reply for a similar query.Unfortunately I'm not able to track the URL of that thread).
Refer this link
1... create a logo using paint shop and save it as tifffile then using RSTXLDMC (is a program name) used to upload logo
2.....create a logo using paint shop and save it as bmpfile then using SE78 you can do this.
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCCIIMAGE/BCCIIMAGE.pdf
http://www.sap-img.com/human/linking-employee-photos-using-sap-archive-link.htm
Transaction OAOR,
- OAOR (Business Document Navigator)
Give Class Name - PICTURES Class Type - OT..... then Execute
It will show you the list, then select ENJOYSAP_LOGO.
On that list, you will find one control with a "create" tab.
Click std. doc types.
Select SCREEN and double-click.
It will push FILE selection screen.
Select your company logo (.gif) and press OK.
It will ask for a description- for instance: "company logo".
It will let you know your doc has been stored successfully.
You can find your logo under ENJOYSAP_LOGO->Screen->company logo.
Just run your ALV program, you should find your company logo in place of the EnjoySAP logo.
Regards,
Beejal
**Reward if this helps

Similar Messages

  • Add Picture to a Module pool screen

    Any anyone know how to load a picture,im module pool
    I have already uploaded a BMP file in se78.
    After that do anyone know how to upload the picture
    in the Module pool screen.

    ok. first create a container then place this picture in ur container.
    For detail.
    go through this program......
    create object cust_container
      exporting
        container_name              = 'MYCONTAINER1'
    create object picture
      exporting
        parent = cust_container
    clear url.
    path = 'Zex'.
    perform get_url using path.
    CALL METHOD picture->set_display_mode
        EXPORTING
          display_mode = cl_gui_picture=>display_mode_fit
    EXCEPTIONS
       ERROR        = 1
       others       = 2
      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 METHOD picture->load_picture_from_url
      EXPORTING
        url    = url
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
               WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    form get_url using  p_path.
    DATA query_table LIKE w3query OCCURS 1 WITH HEADER LINE.
      DATA html_table LIKE w3html OCCURS 1.
      DATA return_code LIKE  w3param-ret_code.
      DATA content_type LIKE  w3param-cont_type.
      DATA content_length LIKE  w3param-cont_len.
      DATA pic_data LIKE w3mime OCCURS 0.
      DATA pic_size TYPE i.
      REFRESH query_table.
      query_table-name = '_OBJECT_ID'.
      query_table-value = p_path.
      APPEND query_table.
      CALL FUNCTION 'WWW_GET_MIME_OBJECT'
           TABLES
                query_string        = query_table
                html                = html_table
                mime                = pic_data
           CHANGING
                return_code         = return_code
                content_type        = content_type
                content_length      = content_length
           EXCEPTIONS
                object_not_found    = 1
                parameter_not_found = 2
                OTHERS              = 3.
      IF sy-subrc = 0.
        pic_size = content_length.
      ENDIF.
      CALL FUNCTION 'DP_CREATE_URL'
           EXPORTING
                type     = 'image'
                subtype  = cndp_sap_tab_unknown
                size     = pic_size
                lifetime = cndp_lifetime_transaction
           TABLES
                data     = pic_data
           CHANGING
                url      = url
           EXCEPTIONS
                OTHERS   = 1.
    endform.                    " get_url
    Regards
    Abhishek

  • How to use table maintenance view in module pool screen

    hi ,
    want to use table maintenance view in a module pool screen so that i can edit, insert, delete and update date in to the ztable.please help.

    You can simply call it via SM30.   Or you can call the table maintence view from any program(report or module pool) using a function module.
      call function 'VIEW_MAINTENANCE_CALL'
           exporting
                action                       = 'U'
                view_name                    = 'Z_Table_Name'
           exceptions
                client_reference             = 1
                foreign_lock                 = 2
                invalid_action               = 3
                no_clientindependent_auth    = 4
                no_database_function         = 5
                no_editor_function           = 6
                no_show_auth                 = 7
                no_tvdir_entry               = 8
                no_upd_auth                  = 9
                only_show_allowed            = 10
                system_failure               = 11
                unknown_field_in_dba_sellist = 12
                view_not_found               = 13
                others                       = 14.
    Regards,
    RIch Heilman

  • Icon display in Module pool screen not visible to some users

    Hi,
    I have added an icon in one of the module pool screen with dynamic quick info.  The page is rendered fine and the info is also displayed well for most users except some.  I can't figure out why the icon is not being displayed for some users.
    Do someone has any solution for this?
    Thanks,
    Sumith

    As I recall, the icons are actually stored in a file on each PC so some users may have a corrupted or out-of-date file with the icons.  You can look for posting on "how to add an icon" to see a discussion on this topic.
    I found some useful info at:
    Create and Add Icons to table ICON?
    Message was edited by: Charles Folwell

  • How to handle The Back button on Module Pool screen

    Hi Gurus,
                  I have created a module pool screen. In that screen I have used some input/output fields(text box) which i have marked mandatory by making the input field as "required" under program tab.
    now when running the screen if no data is entered into these mandatory input field then BACK button does not work. First I have to enter some data into the input filed only then the BACK button works. How should i code so that the back button works even without entering the data into these mandatory fields.

    hi,
    use AT EXIT-COMMAND with the module.
    eg. module user_command at exit command.
    then there will be no problem.

  • How to display image and data in module pool screen?

    Hi,
    I want to display image and relevant data besides the image in module pool screen, I am using docking container to display the image.
    Actually I am able to display image or data any one but not both.
    one more thing I want to display multiple images and their data.
    Please suggest some one if you have any idea.
    Regards,
    Dileep.

    You can try below way, I have used in report.
    DATA: gc_docking              TYPE REF TO cl_gui_docking_container, "#EC NEEDED  "Docking Container
           gc_split                 TYPE REF TO cl_gui_easy_splitter_container, "#EC NEEDED  "Splitter
           gc_top_container         TYPE REF TO cl_gui_container, "#EC NEEDED  "Top Container
           gc_bottom_container      TYPE REF TO cl_gui_container, "#EC NEEDED  "Bottom Container
          gc_document              TYPE REF TO cl_dd_document, "#EC NEEDED  "Document
           gc_events                TYPE REF TO lcl_event_class, "#EC NEEDED  " Local Event Class
           gc_grid                  TYPE REF TO cl_gui_alv_grid, "#EC NEEDED  " ALV Class
    " Creating Docking
    CREATE OBJECT gc_docking
           EXPORTING
             ratio = c_95.
         IF sy-subrc EQ 0.
    * Splitting the Docking container
           CREATE OBJECT gc_split
             EXPORTING
               parent        = gc_docking
               sash_position = c_10 "Position of Splitter Bar (in Percent)
               with_border   = c_1. "With Border = 1 Without Border = 0
         ENDIF.
    *   Placing the containers in the splitter
         gc_top_container = gc_split->top_left_container .
         gc_bottom_container = gc_split->bottom_right_container .
    *   Creating Grid
         CREATE OBJECT gc_grid
           EXPORTING
             i_parent = gc_bottom_container.
       ELSE.
    * Background job handling
         CREATE OBJECT gc_grid
           EXPORTING
             i_parent = gc_docking.
       ENDIF.
    *   Creating the document
       CREATE OBJECT gc_document
         EXPORTING
           style = 'ALV_GRID'.
    Regards,
    Sameer

  • How to get the Grand Total in Module pool Screen

    Hi Frds.
         How to get the Grand Total in Module pool Screen
    Example i have 10 different materials
    for each matarial has different moving . But in my case matarials is doesnt matter here
    10 material Moving Average price to do Frand total and display in one column...
    Please Help me out Frds.
    Regards,
    Kabil

    Hi
    You need to calculate the total in a module of PAI (or PBO) event:
    PROCESS PAI.
       LOOP.....
       ENDLOOP.
      MODULE CALCULATE_TOTAL.
      MODULE CALCULATE_TOTAL.
        GRAND_TOTAL = 0.
         LOOP AT ITAB,
            GRAND_TOTAL = GRAND_TOTAL + ITAB-PWB.
        ENDLOOP.
    ENDMODULE.
    In this way the grand total will be calculated as soon as the user presses enter or another command.
    You can't insert the calculation in the loop of table control, because this loop runs the visible lines only, so it's better to calculate the total out of those loop,

  • Assigning 2 fields of same table in Module pool screen

    Hi,
    I want to assign similar fields of table in module pool screen.
    In one case i directly use the tablename-fieldname and in other case when i try doing the same i get error. I know that this is not possible.
    Is there any way to get around this. The field i am referring to is attached to a custom domain which is having defined fields. In the second assignment i need to retreive the values of the domain and display it in dropdown mode so that the users are able to select it.
    Regards,
    Imran

    The domain only attached with this field?check the same domain attached to any other field and insert that field in the screen.
    shibu
    reward if helpful

  • How to do ICON_EXPAND and ICON_COLLAPSE input fields in module pool screen?

    hi frnds.
    My problem is in module pool screen how to do ICON_EXPAND and ICON_COLLAPSE input fields in module pool screen?And how to do GUI STATUS and GUI TITLE? IN SE80.
      ITS URGENT.POINTS WILL BE REWADED.THANKS  IN ADVANCE.

    Hi,
    Go through this thread.
    [expand and collapse|expand and collapse]
    Cheers,
    Simha.

  • How to retain leading zeros in module pool screen

    Hi experts,
    I have a ztable field of type NUMC4 being displayed on a module pool screen, the value in the field is '0001', but on the screen it displays value as '1' (without leading zeros), When I save the record, Even in the databse it stores as '1'.
    But I have checked in debugging the field always contains '0001' in the program execution and I have also used 'CONVERSION_EXIT_ALPHA_INPUT' in the PBO but no use.
    Pls suggest.
    Thanks,
    Deepak

    Check the screen attributes for the field. There is an option to show leading zeroes.
    edit.
    And how did you see it was stored a 1 and not 0001? Using SE16N? Mind you: with SE16N conversion-exits are executed automatically thus showing 0001 as 1.
    To make sure: double click on the record in SE16N and look if it's still 1 and not 0001.

  • How to insert tabstrip control in module pool screen painter

    Hi all!
    plz tell e how to use tabstrip control in module pool screen painter.Also plz give me an example program using tabstrip control.

    To insert tabstrip just open layout of screen and press on the tabstrip button there .
    Use this souce code further to activate it .
    CONTROLS tabstrip TYPE TABSTRIP.
    DATA: okcode TYPE sy-ucomm,
    dynnr TYPE sy-dynnr,
    flag type flag,
    active like tabstrip-activetab .
    call SCREEN 100.
    *& Module USER_COMMAND_0100 INPUT
    text
    MODULE USER_COMMAND_0100 INPUT.
    data: lv_okcode type syucomm.
    lv_okcode = okcode.
    clear okcode.
    case lv_okcode.
    WHEN 'TAB1'.
    dynnr = '0110'.
    WHEN 'TAB2'.
    dynnr = '0120'.
    WHEN 'TAB3'.
    dynnr = '0130'.
    WHEN 'TAB4'.
    dynnr = '0140'.
    WHEN 'TAB5'.
    "check authorization, if authorization fails
    flag = 'X'. "set the global flag
    active = 'TAB1'. "store active tab in global variable
    dynnr = '0110'. "set the screen number
    WHEN 'BACK' or 'EXIT'.
    leave program.
    ENDCASE.
    IF lv_okcode(3) = 'TAB'.
    tabstrip-activetab = lv_okcode.
    ENDIF.
    ENDMODULE. " USER_COMMAND_0100 INPUT
    *& Module STATUS_0100 OUTPUT
    text
    MODULE STATUS_0100 OUTPUT.
    SET PF-STATUS 'MAIN'.
    SET TITLEBAR 'xxx'.
    IF tabstrip-activetab IS INITIAL OR
    dynnr IS INITIAL.
    tabstrip-activetab = 'TAB1'.
    dynnr = '0110'.
    ENDIF.
    "set the activetab explicilty here
    if flag eq 'X'. "from authorization failure
    tabstrip-activetab = active. "'TAB1'
    clear flag.
    endif.
    ENDMODULE. " STATUS_0100 OUTPUT

  • How to add logo in module pool screen

    Hi Expert,
    I need to display company logo in the module pool screen
    how this can be added ?
    Regards
    Bikas

    Hi,
    create a custom control called 'CUSTOM_CONTROL'
    CONSTANTS: CNTL_TRUE  TYPE I VALUE 1,
          CNTL_FALSE type i value 0.
    data:h_picture       type ref to cl_gui_picture,
         h_pic_container type ref to cl_gui_custom_container.
    data: graphic_url(255),
          graphic_refresh(1),
          g_result like cntl_true.
    data: begin of graphic_table occurs 0,
            line(255) type x,
          end of graphic_table.
    data: graphic_size type i.
    data: g_stxbmaps type STXBITMAPS,
          l_bytecnt  type i,
          l_content   TYPE  standard table of bapiconten initial size 0.
    g_stxbmaps-tdobject = 'GRAPHICS'.
    g_stxbmaps-tdname = 'ENJOY'.
    g_stxbmaps-tdid = 'BMAP'.
    g_stxbmaps-tdbtype = 'BMON'. 
    call function 'SAPSCRIPT_GET_GRAPHIC_BDS'
         exporting
              i_object       = g_stxbmaps-tdobject
              i_name         = g_stxbmaps-tdname
              i_id           = g_stxbmaps-tdid
              i_btype        = g_stxbmaps-tdbtype
         importing
              e_bytecount    = l_bytecnt
         tables
              content        = l_content
         exceptions
              not_found      = 1
              bds_get_failed = 2
              bds_no_content = 3
              others         = 4.
    call function 'SAPSCRIPT_CONVERT_BITMAP'
         exporting
              old_format               = 'BDS'
              new_format               = 'BMP'
              bitmap_file_bytecount_in = l_bytecnt
         importing
              bitmap_file_bytecount  = graphic_size
         tables
              bds_bitmap_file        = l_content
              bitmap_file            = graphic_table
         exceptions
              others                 = 1.
    call function 'DP_CREATE_URL'
         exporting
            type                 = 'image'           
            subtype              = cndp_sap_tab_unknown
            size                 = graphic_size
            lifetime             = cndp_lifetime_transaction
         tables
            data                 = graphic_table
         changing
            url                  = graphic_url
         exceptions
            others               = 4 .
    create object h_pic_container
           exporting container_name =  'CUSTOM_CONTROL'.
    create object h_picture exporting parent = h_pic_container.
    call method h_picture->set_display_mode
         exporting
              display_mode = cl_gui_picture=>display_mode_normal.
    call method h_picture->load_picture_from_url
         exporting url    = graphic_url
         importing result = g_result.
    or you can check the program RSDEMO_CUSTOM_CONTROL
    check link :
    How to insert Image on Screen
    thanks
    Parvathi

  • How to give ** bydefault in password in module pool screen .

    Hi experts
    how to give  *******  by default in password in module pool screen .
    Thanks

    Hi ,
        Double click on the field u will get a pop up window
        i.e. attribute window for that field.
        in that window you have a tab called Program at the bottom.
       in program tab you have many checkboxes.
      check the check box with name *Entry.
      and activate.
    what ever you enter now will be in password formate
    Regards
    Ajay

  • Call module pool screen from ABAP Webdynpro

    Hi All
    I designed one screen in normal classical dynpro in SE80 for module pool program. I want to call that screen layout design in webdynpro view layout.
    So please help me how can i call that module pool screen from my ABAP webdynpro 

    Hi
    Thank you for your great replay. But Mr Ramakrishnappa and Mr Katrice as your reference i go through that but when i insert the program name and screen number program is end with a run time error saying
    dynamic type conflict when assigning reference.
    Please refer the below snap shot

  • Displaying MIR4 attachment list TIF image in module pool screen

    Hi All,
    I have a screen with a custom container and I tried to call a TIF image from MIR4 which is in attachment list(which is stored in archived link).
    I need a function module to display this image in my Module pool screen using the container.
    I tried using below code
    * Create controls
         CREATE OBJECT container_1
           EXPORTING
             container_name = 'CONTAINER'.
    *    create object container_2
    *      exporting container_name = 'PICTURE_CONTROL_2'.
         CREATE OBJECT PICTURE_CONTROL_1
           EXPORTING
             parent = container_1.
    *    CREATE OBJECT PICTURE_CONTROL_2 exporting parent = container_2.
    CALL METHOD PICTURE_CONTROL_1->LOAD_PICTURE_FROM_URL
           EXPORTING
    *    URL    = 'SAPR3://984BE16932C81EE3B2AA1E3B0D12C6FF'
    *      URL    = 'file://E:\Personal\New_Passport4.jpg'
    *       URL    = 'SAPR3://984BE16932C81EE3B2BDF8E44B035648.TIF'
    *URL    = 'SAPR3://SAPR3CMS/get/100/Z1/984BE16932C81EE3B2BDF8E44B035648//.TIF'.
         URL    = 'SAPR3://WebRepository/0020698212/DEMOWORD97SAPLOGO?Version=00000'
         IMPORTING
              RESULT = lv_result.
    CALL METHOD PICTURE_CONTROL_1->set_display_mode
         EXPORTING
           display_mode = PICTURE_CONTROL_1->display_mode_fit_center.
    But I am able to display this URL    = 'SAPR3://WebRepository/0020698212/DEMOWORD97SAPLOGO?Version=00000' and not able to display my archive link image which is in TIF.
    note: Display image of Arc.link Doc.type ZBUSI_TIF (doc.class TIF)
    Please help me on this.
    Thanks
    Geetha Charan

    Hi sai,
    Please refer th procedure.
    For the select-options you might have defined a selection screen.
    Next you can fetch the entire data that you wanted to display in a module pool into an internal table.
    you can call the screen you defined for o/p upon the selection.
    Then, You define a screen XXXX  and a table control in the scree, and in the PAI module of the screen
    you write a chain end chain processing in which you can display the contents of your internal table.
    OR
    if you want the selection also to be in the module pool,  then for displaying the O/P you can definr a sub-screen of the initial screen and you can call that sub-screen on selcting, which can be done with a function code.
    Hope this helps

Maybe you are looking for

  • Restoring issue

    hello, today I woke up to find my phone (iPhone 3Gs) was not working correctly; my internet and other features would not function along with other issues. I figured a simple fix was to restart my phone so I did so. when I turned the phone back on it

  • Ex Rate diff in Migo Vs OB08

    Hi, I'm doing a import po process where my po date was 17/08/2008 and ex rate is Rs.45.00 (as per ob08) and in po header not ticked the fixed price indiicator. Later we are dioing migo on 20/10/2008 that time the ob08 rate is Rs.48.00 but when i see

  • IPhoto has empty events

    Hello, iPhoto has 2 empty events, no images at all in them, can't delete them. What should I do? David.

  • Getting static constants of a class

    hi I have this class: package cl.mejorencasa.pedido.modelos      public class Pedido implements IPedido         public static const     ENESPERA:String   = "En Espera";         public static const     ATENDIENDO:String   = "Atendiendo";         publi

  • Firefox keeps asking to change settings whenever i open it.

    Everytime i open firefox it ask for it to allow to make changes. I have gone into properties and made sure comparability has been unchecked. also my firefox runs so slow, freezes a lot, crashes a lot and scrolling is laggy. I'm running on an i5 surfa