Step 3 Create the Workflow and Set the Schedule

After you've completed Steps 1 and 2, create a workflow for the Lead record and set a schedule for the workflow. Create a single state with a Send Email action and a Set Field Value action for the Lost Lead Email Sent field on the Lead record.

To create the workflow and workflow actions:

  1. Go to Customization > Workflow > Workflows > New.

  2. On the New Workflow page, enter the following properties:

    Section

    Property Name

    Value

    Basic Information

    Name

    Lost Lead Workflow

    Record Type

    Customer

    Sub Types

    Lead

    Release Status

    Released

    Initiation

    Scheduled

    checked

    Schedule

    Saved Search Filter

    Lost Lead Email Search

    Repeat

    check

    Frequency

    Every 30 minutes

  3. Click Save.

  4. The workflow diagrammer, appears with one state.

    Select the state in the diagrammer and click the Edit icon on the State tab in the context panel.

  5. In the Name field, enter Send Lost Lead Email.

  6. Click Save.

  7. To create the Send Email action:

    1. Select the Send Lost Sale Email state in the diagrammer.

    2. Click New Action on the State tab in the context panel.

    3. Click Send Email in the New Action window.

    4. Enter the following properties:

      Section

      Property

      Value

      Sender

      Specific Sender

      Select a sender.

      Recipient

      From Field

      Record: Current Record

      Field: Sales Rep

      Content

      Use Template

      Select a template in the Template dropdown list.

      A portion of the Parameters section of the New Action window.
    5. Accept the default values for the other properties and click Save.

  8. To create a Set Field Value action to set the value of the Lost Lead Email Sent field on the lead record to true:

    1. Select the Send Lost Sale Email state in the diagrammer.

    2. Click New Action on the State tab in the context panel.

    3. Click Set Field Value in the New Action window.

    4. In the Parameters section, select Lost Lead Email Sent in the Field dropdown list.

    5. In the Value section, select Static Value and enable the Checked box.

      A portion of the parameters sectin showing Static Value as selected and the Checked checkbox enabled.
    6. Accept the default values for the other properties and click Save.

Every 30 minutes the saved search runs. If the saved search returns records that match the criteria, NetSuite initiates a workflow instance on each record. The records enter the Send Lost Sale Email state and the Send Email action and Set Field Value actions run. The next time the saved search is run, the saved search will filter out the leads that have the Lost Lead Email Sent field set to true.

Note:

For more information about how NetSuite runs scheduled workflows, see Scheduled Trigger.

Related Topics

General Notices