Disabling Mandatory Fields in Variable Sets when not being displayed
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-28-2008 09:40 PM
Hi,
I'm setting up an account request form in using the Record Producer.
The first field on the page is the account type, and I have created a variable set for each type. In the sets there are variable which are mandatory.
When a type is selected, using the catalog client script, I have hidden all the variable sets besides the one that has been selected.
When all the fields have been filled in and I click Submit, I get the error that the mandatory fields in the invisible variable sets haven't been filled in.
How can I disable the mandatory fields in the invisible variable sets and only make the visable variable sets mandatory fields active?
Thanks in advance!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2008 07:40 AM
Did you try:
g_form.setMandatory(, false)?
--- Pat
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2008 03:26 PM
Yes i've tried that but that would mean writing a line of code for each variable.
Is there a way to turn the whole variable set to not be mandatory?
I have 5 variable sets, each with around 5 - 10 variables in them.
When a value is selected on from the first drop down field, it displays on of the 5 sets. The other sets are in the background and when clicking Submit it still askes for the mandatory fields in the hidden sets to be filled in.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2008 04:29 PM
set the mandatory fields using catalog client script.Dont check the mandatory field checkbox in the variable.
For example,
if(newValue == 'xxx')
{
g_form.setDisplay('field1',true);
g_form.setMandatory('field1',true);
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-29-2008 05:43 PM
Are there no other posibilities?