官术网_书友最值得收藏!

Hands on 3 - displaying a feedback form based on conditions

Let's start with an example: Sara Bareilles is working as a system administrator for Universal Containers. She has received a requirement from her customer success manager to develop a feedback form (containing name, e-mail address, and a rating radio button). Her manager wants to display feedback only when the user's age is greater than 18, and he also wants to expose this visual Flow for unauthenticated access (to people who are not Salesforce users).

To develop this Flow, it's necessary that we first ask for the age as user input, then use the Decision element to check the age; if the age is greater than 18, it will display a feedback form or a sorry message. To develop the Flow, follow these instructions:

  1. Navigate to Setup | Build | Create | Workflow & Approvals | Flows.
  2. Click on the New Flow button; it will open the Flow canvas.
  3. Then navigate to the Palette tab, and drag and drop the Screen element on to the canvas; it will open a Screen element window.
  4. Enter the Name field as Enter your age; you can also add description. Under the Navigation Options section, select Don't show Previous button from the drop-down. Optionally, you can add Help Text as well.
  5. The next task is to add a Date field onto the screen to allow your users to enter their date of birth. On the Screen element, navigate to the Add a Field tab and double-click on the Date field, which is available under INPUTS, to add it to the screen. In the Screen overlays preview pane, click on the Date field to configure its settings by filling out the Label, Unique Name, and Default Value fields, and selecting the Required checkbox under the General Info section, as shown in the following screenshot:
  6. Also, add a validation rule so the user can't enter a future date. To achieve this, use the Date_of_birth < Today() formula.
  7. Now, we will create a formula field to calculate the age from the date of birth field. To create a formula, navigate to the Resources tab and double-click on Formula, which is available under the CREATE NEW section, and create a formula as shown in the following screenshot:

Here, {!Date_of_birth} is the screen input element that we have created in step 5.

  1. Once you are done, click on the OK button.
  2. Now we will use the Decision element to check the age.
主站蜘蛛池模板: 青川县| 襄汾县| 嘉义市| 红河县| 英山县| 苍溪县| 丁青县| 五指山市| 四川省| 六安市| 收藏| 辰溪县| 定襄县| 屏山县| 泰州市| 武定县| 江源县| 江津市| 赣榆县| 开阳县| 衡水市| 天台县| 织金县| 尼勒克县| 浦江县| 郧西县| 雷山县| 贺州市| 巴中市| 安塞县| 彩票| 潞城市| 定日县| 呼图壁县| 托克逊县| 襄垣县| 龙南县| 新野县| 乌鲁木齐县| 乡宁县| 梧州市|