Evening all,
I have an app expression in [survey_status] to force an โAbortโ status in certain โNoโ states.
The Expression Assistant tests as OK but only the โAbortโ part of it works in the form.
And, in an โElseโ state all of the status buttons are missing in the form.
Any pointers please?
IF(
OR(
[Enough_Space_For_Cabinet]=โNoโ,
[Enough_Space_For_HPR]=โNoโ,
[DB_Q1]=โNoโ,
[FOSE_Q1]=โNoโ,
[LPR_Q1]=โNoโ,
[Jum_Con_Q1]=โNoโ,
[Enough_Space_For_Cable]=โNoโ
),
โAbortedโ,
SPLIT(
LIST(โCompletedโ, โIn Progressโ, โOn Holdโ, โAbortedโ),
โ,โ
)
)
Solved! Go to Solution.
Set Editable? to:
NOT(
AND(
OR(
[DB_Q1] = โNoโ,
[Enough_Space_For_Cabinet] = โNoโ,
[Enough_Space_For_Cable] = โNoโ,
[Enough_Space_For_HPR] = โNoโ,
[FOSE_Q1] = โNoโ,
[LPR_Q1] = โNoโ,
[Jum_Con_Q1] = โNoโ
),
[Survey Status?] = "Aborted"
)
)
@Jake_Naude
Below expression should suffice
IF(
OR(
[Enough_Space_For_Cabinet]="No",
[Enough_Space_For_HPR]="No",
[DB_Q1]="No",
[FOSE_Q1]="No",
[LPR_Q1]="No",
[Jum_Con_Q1]="No",
[Enough_Space_For_Cable]="No"
),
{"Aborted"},
{"Completed", "In Progress", "On Hold", "Aborted"}
)
Thanks @LeventK,
Iโve popped that in and the buttons are backโฆ but theyโre all selectedโฆ
Please advise if it possible to for the surveyor to select any of the 4 statuses - as long as the โNoโ condition is not triggered?
Valid If
LIST(
"Completed",
"In Progress",
"On Hold",
"Aborted"
)
Initial value
IFS(
OR(
NOT([DB_Q1]),
NOT([Enough_Space_For_Cabinet]),
NOT([Enough_Space_For_Cable]),
NOT([Enough_Space_For_HPR]),
NOT([FOSE_Q1]),
NOT([LPR_Q1]),
NOT([Jum_Con_Q1])
),
"Aborted"
)
Whoops! Iโd assumed the columns were Yes/No values, but it appears not. Replace NOT(...)
with ("No" = ...)
.
Thanks @Steve,
Sorry I wasnโt clear earlierโฆ The columns below are all Enum with โYesโ & โNoโ values.
Iโve got your expression in the Initial Value and the โAbortedโ button is now auto-selecting when a no condition is presented - thanks!
I appreciate that an Initial Value is editable by the surveyor and that this behaviour is as intended for the Initial Value property.
Hereโs the big askโฆ
Is it possible to take this scenario a step further and prevent a surveyor changing that status whilst the โNoโ condition exists?
IFS(
OR(
[DB_Q1] = โNoโ,
[Enough_Space_For_Cabinet] = โNoโ,
[Enough_Space_For_Cable] = โNoโ,
[Enough_Space_For_HPR] = โNoโ,
[FOSE_Q1] = โNoโ,
[LPR_Q1] = โNoโ,
[Jum_Con_Q1] = โNoโ
),
โAbortedโ
)
Set Editable? to:
NOT(
AND(
OR(
[DB_Q1] = โNoโ,
[Enough_Space_For_Cabinet] = โNoโ,
[Enough_Space_For_Cable] = โNoโ,
[Enough_Space_For_HPR] = โNoโ,
[FOSE_Q1] = โNoโ,
[LPR_Q1] = โNoโ,
[Jum_Con_Q1] = โNoโ
),
[Survey Status?] = "Aborted"
)
)
User | Count |
---|---|
40 | |
34 | |
29 | |
23 | |
17 |