Extracting Numeric Values from Address Fields

  • Myers_Kyle
    Asked on March 28, 2025 at 5:09 PM

    One of my forms includes and Address input form field.

    I would like to use the form calculation widget to calculate the quantity of numerical values included within Address Line 1.

    I.E. Address Line 1: 12345 5th Ave.

    Form Calculation Widget Output: 5

    Should I use the Count function to achieve this?

  • Aries JotForm Support
    Replied on March 28, 2025 at 10:02 PM

    Hi Kyle,

    Thanks for reaching out to Jotform Support. Unfortunately, this is not possible using the count function. As a workaround, you will need to separate each part of the address using a short text element and add two Form Calculation widgets, then create a formula utilizing the floor and log10 functions. Note that this formula will count all the numbers entered in the field. Let me show you how to do it:

    1. Click on the Add Element menu on the left side of the page and add a Short Text element and two Form Calculation widgets. under the Widgets tab

    Extracting Numeric Values from Address Fields Image 1 Screenshot 60

    2. Click on the Wand icon beside the first Form Calculation widget and click on Add Field, select the Short Text field, and click on the Save button.

    Extracting Numeric Values from Address Fields Image 2 Screenshot 71

    3. On the second Form Calculation widget, click on the Wand icon and create the formula. Here's how it looks like:

    Extracting Numeric Values from Address Fields Image 3 Screenshot 82

    Extracting Numeric Values from Address Fields Image 4 Screenshot 93

    Here's the sample result:

    Extracting Numeric Values from Address Fields Image 5 Screenshot 104

    Give it a try and let us know if you have any other questions.

Your Answer