1703
Views
10
Comments
Display Image after choose image file on upload widget

Hi Community,


I want to create the condition : After I choose image in upload widget my image box have to preview image before update to database. 


But my application only display image on database, when I choose another image before I update database my image preview box is stuck.

ToDoWeb_SH.oml
2017-07-05 22-17-18
Henrique Batista
Staff

Hey Syahidah,

You have components on forge for that, but I never used them though.

Checkt this one and this one.

If they don't give you what you're asking, you can always use the event onchange of the file input, and assigning to an image.src the content of the file selected through javascript.

Let me know if it worked.

Cheers,

2022-12-07 04-24-30
Neha Lawange

Thank you Henrique for shaing .I have done the steps according this using javascript.I have used onchange property and assigned to an image.src

2026-02-19 02-54-36
Keerthi Vasan V

Hey Henrique,

I am not an expert in Javascript, so can you please explain me how to implement that refresh action.

Thanks,

Keerthi

2020-02-28 09-46-54
Eduardo Jauch

Hello Keerthi,

If you google "how to load image with javascript" you will find lots of resources teaching how to do it.
Than it is just a matter on adapt the code to use in OutSystems, in the way you want it to work.

Cheers.
Eduardo Jauch

2019-10-15 04-20-55
Tanvi hanbar

Hello oays,

For image preview of image upload, you need to use javascript , here i have attach oml file for image upload ,this will help you perfectly, Or 

else you can check this link , This will defiantly help you :

https://www.outsystems.com/forums/discussion/34169/demo-image-preview/

Please check it once


Thank You

PropertiesExe.oml
2024-05-22 10-21-41
Mohammad Hasib

Tanvi hanbar wrote:

Hello oays,

For image preview of image upload, you need to use javascript , here i have attach oml file for image upload ,this will help you perfectly, Or 

else you can check this link , This will defiantly help you :

https://www.outsystems.com/forums/discussion/34169/demo-image-preview/

Please check it once


Thank You

Hi Tanvi,

Its a very old post ,

In OS11 you dont need any javascript, you just need to assign the variable to your image control which is assigned to upload control.

See the below image.

 

Regards,

2020-11-07 09-14-54
Pranav Shingane

Thank you tanavi . It work

2024-02-16 07-43-18
Amit Verma

oays wrote:

Hi Community,


I want to create the condition : After I choose image in upload widget my image box have to preview image before update to database. 


But my application only display image on database, when I choose another image before I update database my image preview box is stuck.

Hi Oays,

Please try below link

https://www.outsystems.com/forge/component-overview/4081/upload-and-display-profile-image

Hope this will help :)

Thanks,

Amit Verma


UserImage.jpg
Lovely Priyadarshini

Hi oays,

Please check attached OML. This will work perfectly in a way you wants

UploadImage.oml
2022-02-08 09-40-14
Chandrashekhar Mankar

Thanks for this helpful post.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.