​​​​How to create a task responding form to approve and reject a task?

Last Update: June 22, 2018

Here are the steps on how to create a task responding form to approve and reject a task. This use case is applicable for SharePoint Workflow only.

  1. Open the form in design mode.
  2. Create a new form as follows:
    How to create a task responding form to approve and reject a task1.jpg
  3. Select the Approved button control.
  4. In the Rules pane, click on the Add icon to add a new rule, the Rule Manager dialog will open.
    How to auto-shifting Panel control in a form2.jpg
  5. Follow the following steps to add a new rule to the Approved button control:
    A. Change the Rule Name as desired.
    B. Change the Rule Type​ to Action.
    C. Keep the Event Type onClick.
    D. In the Action section, type the following script: updateCurrentUserTask('Tasks', getCurrentUserTaskID(), true, 100, 'Completed', 'Approved', 'Approved') // updateCurrentUserTask and getCurrentUserTaskID are functions.
    E. Click on the Save button to save the rule.
    Note: You can use Assistance Panel to help you adding functions and related parameters, form variables and form controls to Conditions and/or Actions sections.
  6. Select the Rejected button control.
  7. In the Rules pane, click on the Add icon to add a new rule, the Rule Manager dialog will open.
    How to auto-shifting Panel control in a form2.jpg
  8. Follow the following steps to add a new rule to the Rejected button control:
    A. Change the Rule Name as desired.
    B. Change the Rule Name to Action.
    C. Keep the Event Type onClick.
    D. In the Action section, type the following:
    updateCurrentUserTask('Tasks', getCurrentUserTaskID(), true, 100, 'Completed', 'Rejected', 'Rejected') // updateCurrentUserTask and getCurrentUserTaskID are functions.
    E. Click on the Save button to save the rule.

Related Resources:
These resources may not reflect the same exact case steps.
https://www.youtube.com/embed/uQUc0IlzmNg