Skip to main content
Kinetic Community

Presetting values for a form

Overview

This article covers how to prepopulate fields on a form using url parameters.  To do this the field names must be know in advance.

This article assumes that the reader is already familiar with the Kinetic Request console and specifically the Form Builder.

Usage

Use this technique to populate a field before the user views the form or to populate a hidden field. 

**Warning** -- If the field does not exist on the form and the url attempts to prepopulate the field a 500 error will be thrown!!!

Example

A simple example of how this could be useful to a form developer. The company's catalog has a public facing side and a private facing side. There are a series of forms that both public and private users can fill out. If a users that reaches the form is from the public we will show them instructions on how to fill out the for. If the user is from inside the organization, or private users, we will assume they know how to fill the form out. In this case we will not show the instructions.

  1. Add a Radio Button field with the values Yes and No.
  2. Give the radio button a display condition of "Hidden."

    Form Builder
     
  3. Add a Section and give it a display condition of "Conditional."
  4. Give the section a condition expression. (When evaluated to True the section will be Visible)

    Form Builder 1
     
  5. Add a Plain Text field inside of the section that will have the instructions to show to the public user.
  6. Create a link to the form, from the public portal, that has the parameter ?values[Hidden]=No appended to the end. (the ? starts a query string and the & is used to append multiple parameters)

Now when a users from the public visits this form they will see a section that gives them instructions on how to fill out the form.

Form View

And users from the organization will not see the instructions.

Form View 2