Text input disappears when clicking elsewhere

Hello,

 

I created a Interface with a wizard including some text boxes, drop downs and radio buttons on the first page and 4 text boxes on the second page of the wizard. 

When the interface is opened as a standalone tab in chrome, on the first page everything works fine. Including all expressions.

On the second page when I type something in one of the text boxes and click on something else the text disappears. When I do this on the interface in the designer everything works the way it should.

 

Any solutions?

  Discussion posts and replies are publicly visible

  • Could you post an screenshot of the code in question?

    My first thought is that you're incorrectly (or not) saving the relevant field into a local variable or rule input.
  • The saveinto and value variables should match. The textbox displays value (set via literal or variable, in your case I'm assuming variable) and when you change the value in the interface the box refreshes and display the current value of the variable in the value attribute. So to see the value entered to be displayed all the time you have to use the same variable for the value.

    Both the value and saveinto takes expressions so you can configure it per your requirements, like default value etc.

    In Interface designer for a more accurate test, click on Test button on the top each time.
  • Please make sure you specified the same variable in value and saveInto. Example below:
    value: ri!vehicleInfo.make,
    saveInto: ri!vehicleInfo.make, 

     

    If there is any discrepancy, value will be wiped-out.

  • This is the code.

    =load(
    local!test: 'type!{www.appian.com/.../2009}LabelValue'(),
    local!currentStep: 1,
    local!steps: {"Step 1", "Step 2", "Confirmation"},
    a!formLayout(
    label: "Aanvraag",
    contents: {
    a!milestoneField(
    steps: local!steps,
    active: local!currentStep
    ),
    a!sectionLayout(
    contents: {
    a!textField(
    label: "Naam",
    labelPosition: "ABOVE",
    value: ri!Naam,
    saveInto: ri!Naam,
    refreshAfter: "UNFOCUS",
    required: true,
    validations: {}
    ),
    a!radioButtonField(
    label: "Geslacht",
    labelPosition: "ABOVE",
    choiceLabels: {"Man", "Vrouw"},
    choiceValues: {true(), false()},
    value: ri!Geslacht,
    saveInto: ri!Geslacht,
    required: true,
    choiceLayout: "STACKED",
    validations: {}
    ),
    a!dateField(
    label: "Geboorte datum",
    labelPosition: "ABOVE",
    helptooltip: "Minimale leeftijd is 18 jaar.",
    value: ri!GeboorteDatum,
    saveInto: ri!GeboorteDatum,
    required: true,
    validations: if(edate(today(), -216) > ri!GeboorteDatum, null, "U moet minimaal 18 Jaar oud zijn voor een aanvraag.")),
    a!dropdownField(
    label: "Kies uw pakket",
    labelPosition: "ABOVE",
    placeholderLabel: "--- Select a Value ---",
    choiceLabels: {"Budget", "Standard",
    "Premium",
    "Family"},
    choiceValues: {1, 2,
    3,
    4},
    value: ri!PakketKeuzeJ,
    saveInto: ri!PakketKeuzeJ,
    showwhen: if(and(edate(today(), -804) < ri!GeboorteDatum,edate(today(), -216) > ri!GeboorteDatum),(ri!GeboorteDatum),false),
    required: true,
    validations: {}
    ),
    a!dropdownField(
    label: "Kies uw pakket (Senior)",
    labelPosition: "ABOVE",
    placeholderLabel: "--- Select a Value ---",
    choiceLabels: {"Budget Senior", "Standard Senior",
    "Premium Senior",
    "Pensioner"},
    choiceValues: {1, 2,
    3,
    4},
    value: ri!PakketKeuzeS,
    saveInto: ri!PakketKeuzeS,
    showwhen: if(isnull(ri!GeboorteDatum), false, edate(today(), -804) >= ri!GeboorteDatum),
    required: true,
    validations: {}
    ),
    a!checkboxField(
    label: "Extra pakketten",
    labelPosition: "ABOVE",
    choiceLabels: {"Family Voordeel", "Student Extra",
    "Totaal Pakket",
    "Totaal Pakket Extra"},
    choiceValues: {1, 2,
    3,
    4},
    value: ri!Extras,
    saveInto: ri!Extras,
    showwhen: OR(ri!PakketKeuzeJ="1",ri!PakketKeuzeJ="2",ri!PakketKeuzeJ="3",ri!PakketKeuzeS="1",ri!PakketKeuzeS="2",ri!PakketKeuzeS="3"),
    choicelayout: "STACKED"),
    a!radioButtonField(
    label: "Bent u werkzaam?",
    labelPosition: "ABOVE",
    choiceLabels: {"Ja", "Nee"},
    choiceValues: {true(), false()},
    value: ri!Werkzaam,
    saveInto: ri!Werkzaam,
    showwhen: OR(ri!PakketKeuzeJ="1",ri!PakketKeuzeJ="2",ri!PakketKeuzeJ="3",ri!PakketKeuzeS="1",ri!PakketKeuzeS="2",ri!PakketKeuzeS="3"),
    required: true,
    choiceLayout: "STACKED",
    validations: {}
    ),
    a!radioButtonField(
    label: "Bent u met pensioen?",
    labelPosition: "ABOVE",
    choiceLabels: {"Ja", "Nee"},
    choiceValues: {true(), false()},
    value: ri!Pensioen,
    saveInto: ri!Pensioen,
    showwhen: ri!Werkzaam = false(),
    required: true,
    choiceLayout: "STACKED",
    validations: {}
    ),
    a!radioButtonField(
    label: "Ontvangt u een inkomen?",
    labelPosition: "ABOVE",
    helptooltip: "Is uw partner hoofdverdiener?",
    choiceLabels: {"Ja", "Nee"},
    choiceValues: {true(), false()},
    value: ri!Inkomen,
    saveInto: ri!Inkomen,
    showwhen: ri!Pensioen = false(),
    required: true,
    choiceLayout: "STACKED",
    validations: {}
    ),
    a!dropdownField(
    label: "Hoeveel verdiend u per jaar?",
    labelPosition: "ABOVE",
    helptooltip: "Of uw partner?",
    placeholderLabel: "--- Select a Value ---",
    choiceLabels: {"Minder dan 32.000", "Meer dan 32.000 en minder dan 64.000",
    "Meer dan 64.000"},
    choiceValues: {1, 2,
    3},
    value: ri!InkomenHoeveel,
    saveInto: ri!InkomenHoeveel,
    showwhen: or(ri!Werkzaam, ri!Pensioen, ri!Inkomen),
    required: true,
    validations: {}
    ),
    a!fileUploadField(
    label: "Upload hier een kopie van uw identiteitsbewijs",
    labelPosition: "ABOVE",
    value: ri!BestandenUpload,
    saveInto: ri!BestandenUpload,
    required: true,
    validations: {}
    )
    },
    showWhen: or(local!currentStep = 1, local!currentStep = length(local!steps))
    ),
    a!sectionLayout(
    label: "Account aanmaken",
    contents: {
    a!textField(
    label: "Gebruikersnaam",
    labelPosition: "ABOVE",
    value: ri!Gebruikersnaam,
    saveInto: ri!Gebruikersnaam,
    required: true,
    validations: {}
    ),
    a!textField(
    label: "E-mailadres",
    labelPosition: "ABOVE",
    value: ri!Emailadres,
    saveInto: ri!Emailadres,
    required: true,
    validations: {}
    ),
    a!textField(
    label: "Wachtwoord",
    labelPosition: "ABOVE",
    value: ri!Wachtwoord,
    saveInto: ri!Wachtwoord,
    required: true,
    masked: true,
    validations: {}
    ),
    a!textField(
    label: "Herhaal wachtwoord",
    labelPosition: "ABOVE",
    value: ri!HerhaalWachtwoord,
    saveInto: ri!HerhaalWachtwoord,
    required: true,
    masked: true,
    validations: {}
    )
    },
    showWhen: or(local!currentStep = 2, local!currentStep = length(local!steps))
    )
    },
    buttons: a!buttonLayout(
    primaryButtons: {
    a!buttonWidgetSubmit(
    label: "Done",
    style: "PRIMARY",
    showWhen: local!currentStep = length(local!steps)
    ),
    a!buttonWidget(
    label: "Next",
    value: local!currentStep + 1,
    saveInto: {
    local!currentStep
    },
    showWhen: local!currentStep <> length(local!steps),
    validate: true
    )
    },
    secondaryButtons: {
    a!buttonWidget(
    label: "Go Back",
    value: local!currentStep - 1,
    saveInto: local!currentStep,
    showWhen: local!currentStep > 1
    ),
    a!buttonWidgetSubmit(
    label: "Cancel",
    style: "SECONDARY",
    skipValidation: true
    )
    }
    )
    )
    )
  • The save input into and display value are the same for all. That's not it.
  • This is really weird, I tried everything now. Every text box I add and link to an interface input does the same thing. The existing ones on the first page of the wizard are the only ones that work. All text input of new text boxes added now disappear regardless of location in the interface. I tried making another interface with text boxes and calling it on the existing interface, same thing
  • 0
    Certified Lead Developer
    in reply to sjoerds0001
    Did you say the input disappearing issue is happening when it's used in an in-process task? Can you post a screenshot of your task configuration?
  • It's nothing complete. I'm making a testcase for a group of colleagues to present the capabilities of Appian. For now I created an interface to show the dynamic capabilities of that component. The processmodel connected to the interface is just start to end. I saved the interface as an application and opened it trough tempo. The application then opens standalone in another tab. That's where the problems are. half the forms textboxes work properly and the ones I add now don't. Text typed in immediately disappears when clicked elsewhere. When I use the interface in designer and type something in the textboxes everything works. I can see the text not disappearing and the value change on the interface inputs tab
  • I pasted your code in a new interface and defined the necessary rule inputs, and everything works fine. Assuming your rule inputs are correct, then the problem is not in the SAIL code. Take a look at how you're binding process data to your form inputs. For example, make sure all the types match. You could also post a screenshot of your form configuration in the user input task.
  • well I solved it sort off. I came to the conclusion that something had to be seriously broken in the designer. I copied the code. Ditched the interface and process connected. I created a new interface with a form, not a wizard and pasted the code. Now it's working. Thanks for the help.