cancel
Showing results for 
Search instead for 
Did you mean: 

How to view an Image in ABAP Webdynpro on button action

rabikiran_sahu
Participant
0 Kudos

Hi Experts,

I want to view an image on a button action without creating a new view or window.

I just need to display the image.

Thanks,

R Sahu

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hii,

enter the image with the help of mime,initially make the image as invisible and make it visible on action.

I think it should help

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Rabi,

Add Context Attribute "SOURCE_IMG" with type String.
Add Image UI "img_id" in layout and bind its source with this context attribute.

on any method where you want to change/show image dynamically, put this code :

here url can be path to image on local or any url-path for web image.

call method wd_context->set_attribute
       EXPORTING
         name = 'SOURCE_IMG'
         value          = url .

I hope this is what you are looking for.

Thank you

Meet Vajaria

rabikiran_sahu
Participant
0 Kudos

Thank you all for valuable replies.

Former Member
0 Kudos

Hi kiran,

Its great to hear you solved it.

Kindly share your answer bit more clearly so that it helps others...

Cheers,

Kris.

rabikiran_sahu
Participant
0 Kudos

Hi charanjasti ,

When I click on the action I want the image to be like in a browser screen only with a close option in that browser.

Thanks,

RK Sahu

Former Member
0 Kudos

Hi Kiran,

I think without any view or window you can't get this.

You have to display Image somewhere.

Cheers,

Kris.

rabikiran_sahu
Participant
0 Kudos

Hi Kris,

This is solved.

I am able to display the image without using a view or window.

Just creating an URL for that image and call Onaction click.

We can work on the window resize options also.

Thanks,

Rabi