cancel
Showing results for 
Search instead for 
Did you mean: 

Make field obligatory

Former Member
0 Kudos

Hi all,

We created a request form in VC, but for 1 field (a message box), we want to make this obligatory only when a certain button is clicked. Is that possible in VC? And how?

Fow example:

If I click u201CInvalid Requestu201D or u201CAdd additional informationu201D, the inputbox u201CMessageu201D needs to be obligatory.

Not with u201Cvalid requestu201D.

Can I add this in the u201Cactionu201D of the button?

The current actions that I have now in u201Cinvalid requestu201D:

ASSIGN u201Cfalseu201D to validation

ASSIGN u201Cfalseu201D to info

VALIDATEREQUESTCOMPLETEEVENT

Regards,

Hans

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

In order to do so, you need to add (for example) 4 fields from type - Boolean (from the Define Data Editor):BOOL1, BOOL2, BOOL3 and BOOL4.

But not make them visible.

Highlight the first dropdown list control (DD1) and in the Configure Task Panel, set its Enable Property to =@BOOL1

For DD2, set Enable property to =@BOOL2

For DD3, set Enable property to =@BOOL3

For DD4, set Enable property to =@BOOL4

In the Action Property Editor of the DD1 dropdown list, set three actions:

1. Assign Action. Set value - TRUE to Target field - BOOL2

2. Another Assign Action. Set value - FALSE to Target field - BOOL3

3. Another Assign Action. Set value - FALSE to Target field - BOOL4

For DD2

1. Assign Action. Set value - TRUE to Target field - BOOL3

2. Another Assign Action. Set value - TRUE to Target field - BOOL4

Also you can add to the Toolbar of the Form View, the Toggle button Control and set its value according to the dropdown lists Enable Expression

Hope it helps

Best Regards,

Luba

PradeepBondla
Active Contributor
0 Kudos

Hans,

You can very much do that... take a store (data store) define a boolean element (say validate-now) in that make it false as default. and tie this data store boolean element to "Required" field of your validation block.

Now onclick of a button, first send the value "TRUE" to our defined data store value (validate-now).

So when you click on button , validation will be true and then only your validations will trigger.

Let me know if any more questions.

Thanks,

PradeeP

Former Member
0 Kudos

Hi,

I have the dropdown lists and they are looking like :-

DD1

DD2

DD3

DD4

On Click of the DD1 the DD2 should be Enabled other wise disable like wise for other dropdown lists.So, Please Suggest some inputs for proceeding.

Former Member
0 Kudos

Hello Hans,

I guess you are taking the right approach. I haven't tried this though. will test it out on Monday and get back.

Regds,

Kiran