Can I create a drop down box that shows a Code (in this case a trip code) and link it to another box where the Name of the trip corresponding to that code would be shown?

1 Answer 1


You can easily change the values of other fields on your Cognito Forms using calculations. Here are two common ways to do this:

  1. Add a Calculation field

    Add a Calculation field next to your Trip Code dropdown called Name of Trip. Specify a calculation for this field that calculates the name of the trip based on the code selected in the Trip Code field. For example, =TripCode = "SkiGetaway" ? "Colorado Ski Retreat" : TripCode = "Cruise15" ? "Alaskan Cruise" : "No Trip Selected"

  2. Calculate a Default Value

    As an alternative, you can also update the values of other fields on your form when changes occur by using a calculation to update the current value of a field. Many of the field types support a Default Value, which can actually be a calculation that references other fields on your form. If you added a Textbox field instead, called Name of Trip, and used the above calculation as the Default Value, the text in this field would automatically change when the trip code changes. This is useful when you still want the user to be able to change the calculated value, such as an auto-calculated end date for a reservation.

Check out our documentation on calculations for more details of how to write powerful calculations in Cognito Forms:


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.