Best Practices

 View Only
  • 1.  Pulling User information into the form automatically

    Posted 10-21-2021 09:44
    Edited by Ian Chamberlain 10-21-2021 10:05

    Including information about the person who is filling in the form can be useful for many reasons. Including the users full name, email or any information that is in their ProntoForms user profile that can be used to customize your destinations.

    When using a Text input question, there is an option under the Properties tab to "Use mobile user's Username as the default value". This will automatically set the answer to the Username of who ever opens the form. 

    Next we will need to leverage a "User Group" data source to allow us to lookup the username, instruction on creating that data source can be found here. Once you have your data source created (or use an existing one) we are all set to pull in some additional information. 

    In the form, create a Dropdown question and use the new User List data source as the source of the options, using the "Username" as the column to display. This question is going to be used a lookup. 

    Next we will need to think about what kind of information you want to include in the form. For my example, I will just use First and Last name and email but you can use any data from the user profile. Create 3 new Text questions, one for First name, Last name, and email. 

    Back on the User lookup dropdown question, we will then push the values into those questions like the following: 

    Now the final piece of the puzzle, using Conditional Logic to make this all happen right when the form is opened. We can evaluate whether or not the first question (which is set to a default value) is answered and then set the value of the dropdown question to then push the other values. 


    To tidy things up a little bit in the form, change the first 2 questions (the default username and the username lookup) to "Hidden on Device" and "Hidden on Report" because we dont need to see the Username. Then use a String Concatenation question to combine the First and Last name into a Full Name

    Final Results: 

    Additional Use Cases:

    Using additional fields in a user profile, like role or Organization, you can trigger different conditional logic rules based on the role of the person who logs in. 

    Do you use this in any of the forms that you are currently using? Are you using any of these techniques to drive conditional logic in your form? 


    Ian Chamberlain
    Implementation Specialist

  • 2.  RE: Pulling User information into the form automatically

    Posted 10-22-2021 07:36
    Not yet, but I will be. Thanks for the info.

    Scott Gilleland
    Senior Field Service Engineer
    Messer Cutting Systems

  • 3.  RE: Pulling User information into the form automatically

    Posted 05-11-2022 02:17
    Thanks Ian, this has helped me with a automated manager dispatch workflow based on the submitters related manager.

    A caveat to mention if you are using external sources: The username (in my case email address) in all lookups to the external data needs to be identical, in my situation - case sensitive!
    I got caught out by our ProntoForms users usernames were in lowercase, and the data source I was using as the lookup had some upper case characters in it, therefor it didn't find the matching data, once I adjusted the data source lookup field to all lowercase and now this is working great.


Reminder: Content posted to our Community is public content.  Please be careful not to post Intellectual Property that you do not have permission to share.  For more information please refer to our Terms Of Use