Expand my Community achievements bar.

cant get addinstance to work

Avatar

Former Community Member

Hi all,

I have a form that is 8 pages long and nearly every field the client needs to be required. In addition, there is a "section 2" that can be independent of the other sections when certain conditions apply. Form validation will occur when the user submits the form.

I've set the form as flowed and each section is positioned except "section2". When the user selects a checkbox indicating they only need to fill out section 2, the other sections become hidden. The problem is when the form is failing validation because of all the hidden required fields.

I have been trying to change the form to add an instance of each page when the form is initialized so that instead of hiding each section I can remove the instance and the validation would not fail on section 2 only cases.

So far, I have been unsuccessful geting the sections to add an instance when the form is opened. I've tried adding script to the initial event, the doc ready event etc.

Anyone have a sample they can point to on how best to accomplish my task?

0 Replies