How to extract digits to String Widget and make it hidden?

  • hatzbs
    Asked on August 26, 2016 at 1:47 AM

    In my form I'm trying to extract first 3 digits of DISPATCHER ID into ID field using String Widget; getting no result at all. Please advise.   https://form.jotform.me/62340964958467

  • BJoanna
    Replied on August 26, 2016 at 3:12 AM

    Substring widget is used to capture characters from input fields, such as text box field. Considering that your "DISPATCHER" field is dropdown field Substring widget in not able to capture characters from that field. 

    Possible workaround is to add one additional text box field to your form, which can be hidden, and then to pass data from your dropdown field to text box field, with conditional logic. Then you can use Substring widget to capture characters form your new text box field and to pass it to ID field. 

    How to extract digits to String Widget and make it hidden? Image 1 Screenshot 20

    Here is my demo form: https://form.jotform.com/62381582340958 

    Feel free to clone it.

    Hope this will help. Let us know if you need further assistance. 

  • hatzbs
    Replied on August 26, 2016 at 5:20 AM

    OK, worked as you said; I need to make STRING WIDGET HIDDEN & CANNOT. KINDLY ADVISE & Thx.

  • Nik_C
    Replied on August 26, 2016 at 5:34 AM

    I checked your form and I see that solution provided by my colleague worked for you:

    How to extract digits to String Widget and make it hidden? Image 1 Screenshot 30

    If I understood you right, you want to make String widget field hidden, to do that please try to paste this CSS in your Custom CSS field:

    #input_10 {

    visibility: hidden!important;

    }

    That will hide your String widget field from the form:

    How to extract digits to String Widget and make it hidden? Image 2 Screenshot 41

    Hope it helps.

    If you need further assistance please let us know.

    Thank you!

  • hatzbs
    Replied on August 28, 2016 at 6:43 AM

    Your suggestion works. However, I need to know HOW YOU IDENTIFIED THE SUBSTRING FIELD AS #input_10. The form you're viewing is only a TEST form. Thx.

  • Welvin Support Team Lead
    Replied on August 28, 2016 at 10:26 AM

    You'll have to view the form in your browser and find the field ID by using the inspect element method. This guide from Google:

    https://developers.google.com/web/tools/chrome-devtools/iterate/inspect-styles/?hl=en

    We can help you find it, just share us the correct form URL.

  • hatzbs
    Replied on August 28, 2016 at 2:05 PM

    I found an easier way - inspecting the EMAIL FIELDS for a form shows the FIELD #. Please publish this info. Thx.

  • Nik_C
    Replied on August 28, 2016 at 2:15 PM

    That is the way as well, thank you for sharing this information!

    Please let us know if you have any further questions.

    Thank you!