Expand my Community achievements bar.

Learn about Edge Delivery Services in upcoming GEM session

preSubmit event and mandatory

Avatar

Level 6

Hi,

I've designed one questionary form. On this form i have radiobuttons groups with preSubmit event which makes it mandatory depends on some condition.

So? if I'll try to submit form and this radiobuttons are emty they should become mandatory and gives me the message - "at least one requered field...".

But there one problem, it is not working properly - fields becomes mandatory but i didn't receive message and form can be posted with empty fields.

Test case:

1) open form

2) fill out questions 33,34,35

3) press submit  and press yes

4) it will ask you to submit form, but on the form there are mandatory unfilled radiobuttons.

What is the problem? Why mandatory fields ignored?

Thanks in advance,

Paul Butenko

8 Replies

Avatar

Former Community Member

Your attachment seems to be messed up ......

You may want to try setting the RadioButtonList as Mandatory and not the individual Radio Buttons.

Paul

Avatar

Level 6

Hi,

Actually I set manadatory to whole RadioButtonList.

1.JPG

What do you mean "messe up"?  I dont' have any warnings or errors in Designer.

I attached archive with form and xml file(rename extension to rar), would you be so kind to have a look?

Avatar

Former Community Member

I didn't get the data file with the 1st attachment so the form woudl not generate properly. I have it now with the Rar file.

I do not know specifically what the issue is but when I render there is a default selection for the radio button group so when I hit the submit button an item is slected in the group list. As a test I added a button that will reset the data so that nothing is slected and when I hit the submit it will not allow it because I have at least 1 empty field.

Am I missing something?

Paul

Avatar

Level 6

Hi,

This is example data file for the form. If you will render form with it (in Designer for example), and press submit button - form will start to submit, but on pages 12 - 25 there is empty radiobuttons groups.

See screenshots.

1.JPG

31.JPG

4.JPG

5.JPG

Thank you in advance

Avatar

Former Community Member

There is something weird going on here .....I set the RadioButtonList as Mandatory and when it displays the red box appears around it. If I try to reset the data in only the 1st instance I cannot ...all instances get the same setting. I think that is what is happening to you. It looks like it might be a bug. If I do the same thing on a fresh form with no code and a single instance it works fine.

I suggest that you open an incident with support.

Paul

Avatar

Level 6

Thanks for answer.

How can i open incident with support?

Paul Butenko