Skip to Content
avatar image
Former Member

Refer to MIME image in ALV Table

Hello All,

I know now how to refer to an image in the AVL Table.

But I want to refer to the MIME image.

The filename is not enough?

Anyone an idea?

Thanks & Regards,

Chris Bogers

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Feb 23, 2010 at 12:18 PM


    1. Here you have to mention the URL where your mime objects are stored.

    data: mime_repository type ref to if_mr_api,
          content type xstring,
          mime_type type string,
          url type string value 'SAP/BC/WebDynpro/SAP/ZTREE/s.bmp'.
    mime_repository = cl_mime_repository_api=>get_api( ).
    call method mime_repository->get
    exporting i_url = url
    importing e_content = content  e_mime_type = mime_type.

    2. Finally you have the value in an XString which you can bind to the context attribute.

    DATA lo_el_context TYPE REF TO if_wd_context_element.
      DATA ls_context TYPE wd_this->element_context.
    * get element via lead selection
      lo_el_context = wd_context->get_element( ).
    * set single attribute
        name =  `CONTENT`
        value = content ).

    Note : CONTENT is my context attribute binded to image UI.

    Add comment
    10|10000 characters needed characters exceeded