Reactive web Upload widget validation when when we browse to upload and cancel
Application Type
Reactive

Hey all,

I'm using the upload widget for uploading images in a form.When I'm replacing/updating the already uploaded image and click on the widget to browse files and upload but close the window the validation changes to invalid even though the already selected image is there .


How do i solve this

Thanks & Regards

Hi Kanishka,

please check the attached .oml for upload widget on reactive, that could help you solving your problem. Mostly default form validation occurs while submit not on file upload cancel button. 

Could you please provide more information or oml file?


TestUpload.oml

Hi,

Are you closing the window without clicking on save after replacing/updating image and come back on form and then without uploading images click on save?

Is that your test case?

Can you please clear,

Regards,

Komal

Hey,

I'll walk you through my test case .

I uploaded a image in my form and saved it .Then later when i came back to make updates/edit the form i clicked the upload widget which opened up the window to browse files here I didn't choose any image and just clicked on the close window button . The image that was fetched from my database which is stored in a binary variable of upload widget is still there .So I proceed and save my form it gives me invalid value validation error for the upload widget .  Since the earlier image was not changed the validation still should be valid and not change everytime the upload widget is clicked .

Hi,

I did same as you did, i can still able to see the form is valid and the upload image widget is also valid. Are you using built in validation or you are using some validation manually in save action on upload widget or any other widget in form that may be leads to invalid validation, 

Did you debug the action, and seen that what values are returning by upload widget in your mentioned test case,

In addition to my previous post here I  have attached OML for your reference,

Regards,

Komal

UploadImage.oml

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