Project and Portfolio Management Practitioners Forum
cancel
Showing results for 
Search instead for 
Did you mean: 

Set a field required based on an autocomplete Field Value

Highlighted
Deep Mehta
Regular Collector

Set a field required based on an autocomplete Field Value

Hi
We are trying to set a field Required based on a specific value of another Field (autocomplete List)in 7.5 sp2.
I am trying to achieve this by using an UI rule (Attached)and it's not working.
Can someone tell how can this be done?
Thanks
7 REPLIES
Sangiliraja_1
Collector

Re: Set a field required based on an autocomplete Field Value

Hi Deep,

It is easier to do. Please follow the Demand Management Configuration Guide.

Also the UI Rule is Case sensitive. You have to write "setFieldRequired(true)". Also make sure that Rule Logic is set to "UI Rules" and not "SQL Default".

Please let me know if this helps or share the snapshot of the rule.

Thanks
Sangiliraja.P
Deep Mehta
Regular Collector

Re: Set a field required based on an autocomplete Field Value

Sangiliraja,

I have already tried what you mentioned in your reply. (see my attached screenshot in my Main question). It's still not working for autocomplete field.
The rule works if I change the dependent Field to a dropdown Validation field.

Thanks,
Deep
Sangiliraja_1
Collector

Re: Set a field required based on an autocomplete Field Value

Hi Deep,

I have tried with a ACL and it worked for me.

Can you try with some other ACL fields.

Attaching my test rule.

Thanks
Sangiliraja.P
Deep Mehta
Regular Collector

Re: Set a field required based on an autocomplete Field Value

Hi,
I was able to implement the rule for other ACLs.
My current ACL field is a dependent field and is being populated by outcome of a previous Field.
When I try to add this ACL in dependency window, and set the condition as "is equal to" a "constant value".. the value section appears as a text box instead of Auto Complete. ( See Attachment )
Can someone tell why is it happening?

Workaround for me is to create a hidden field and populate it with current ACL output data via a rule. Any comments ?


Semenov Alexand
Esteemed Contributor

Re: Set a field required based on an autocomplete Field Value

Hi,Deep.
Try sample from attach
Sangiliraja_1
Collector

Re: Set a field required based on an autocomplete Field Value

Hi Deep,

You are right. It is not working when the ACL is a sql getting value on the fly. Your option of getting it from a hidden field is a good one. Nice idea.

Thanks
Sangiliraja.P
Deep Mehta
Regular Collector

Re: Set a field required based on an autocomplete Field Value

My Workaround : create a hidden field and populate it with current ACL output data via a rule
//Add this to "OnDomLoad" event