Conditionally Autofilling Text Field

Certified Associate Developer

I'm trying to conditionally autofill a text field based on two other text fields above it. I've gotten the value in the text field to display correctly however the value doesn't save into the variable set in the "saveInto" property. I've tried changing the "refreshAfter" property and using local variables with the "a!refreshVariable" function with both the "refreshOnVarChange" and "refreshAlways" options. I've also tried the "a!save" function both inside and outside of the if statement.

Does anyone have any suggestions on how I could do this or know where my problem is? I'm pretty new to Appian so I may be going about this completely wrong.

a!textField(
                    local!SealModel: a!refreshVariable(refreshAlways: true()
                      /*refreshOnVarChange: {*/
                        /*local!SealManuf,*/
                        /*local!SealPartNum,*/
                        /*local!SealModel*/
                      /*}*/
                    ),
                    label: "Seal Model/Type:",
                    labelPosition: "ABOVE",
                    value: if(
                      and(
                        local!SealManuf = "XYZ",
                        not(isnull(local!SealPartNum))
                      ),
                      mid(local!SealPartNum, 8, 3),
                      local!SealModel
                    ),
                    /*a!save(local!SealModel, mid(local!SealPartNum, 8, 3)),*/
                    saveInto: local!SealModel,
                    refreshAfter: "UNFOCUS",
                    /*disabled: if(and(ri!SealManuf = "XYZ", not(isnull(ri!SealPartNum))),*/
                    /*true(), false()),*/
                    validations: {}
                  ),

  Discussion posts and replies are publicly visible

Parents Reply Children
No Data