How do I get an autocomplete to populate a second field?

  • ChessGuru
    Asked on August 21, 2015 at 3:23 AM

    I am creating a form where a user can select from a long list of classes (50+), hence using auto-complete.  I want the user to be able to select the class from the autocomplete and then see the cost of that class (each class is a different price).

    What is the easiest way to achieve this? 

  • Welvin Support Team Lead
    Replied on August 21, 2015 at 6:39 AM

    If you want a simple method to calculate the values, you can use our dropdown field. In the dropdown field, you can add calculation values:

    How do I get an autocomplete to populate a second field? Image 1 Screenshot 30

    Then simply add our calculation widget: https://www.jotform.com/help/259-How-to-perform-calculation-in-the-form.

     

    But if you really want to use the auto complete widget, the only way you can update the value in the next field would be to add a mathematical condition. This also means that you need to add 50+ conditional logic and that's quite a lot.

    Here's our guide for condition:

    https://www.jotform.com/help/268-How-to-Insert-Text-or-Mathematical-Caculation-into-a-field-using-a-Condition

    Here's an example conditional logic that you have to add:

    How do I get an autocomplete to populate a second field? Image 2 Screenshot 41

    Thanks