FAQ: SuiteFlow

Review the questions and answers below to learn more information about SuiteFlow. The questions and answers are ordered by topic in the following way:

Questions About Email

The following FAQs describe issues related to SuiteFlow and email.

How do I send an email using SuiteFlow?

Use a delay on a transition to a state that contains a Send Email action or set a delay on the Send Email action itself. See Scheduling an Action, Scheduling a Transition, and Welcome Email Sent to Customers Three Days After First Order Workflow.

Can I include attachments in the Send Email action?

Yes, you can send attachments using the Send Email action. To send multiple attachments in one Send Email action, create a .zip file that includes all the files to send. See Send Email Action.

You can also send attachments by creating a custom action using SuiteScript. For more information, see Custom Action. In the custom action, send attachments with email.send(options) or email.sendBulk(options).

In the Send Email action, are Customer, Email, and Entity the same thing?

Yes. A workflow based on a Sales Order, or any other record type that specifies a customer can have the following three values available in the Field dropdown list:

  • Customer

  • Email

  • Entity

In this case, for a Send Email action, each of these values reference the same object. If you choose Customer, Email, or Entity, NetSuite uses the email address associated with the customer:

The options in the Field drop-down list. The Customer, Email, and Entity options are highlighted in the screenshot.

Questions About Fields

The following FAQs describe issues related to fields and SuiteFlow.

How do I set field values using SuiteFlow?

Use the Set Field Value action. See Set Field Value Action.

How do I hide a field using SuiteFlow?

Use the Set Field Display Type action. See Set Field Display Type Action.

How do I make a field required using SuiteFlow?

Use the Set Field Mandatory action. See Set Field Required Action.

Can I set multiselect fields using SuiteFlow?

You cannot set the value of multiselect fields for existing records, either with the Set Field Value action, or with the Send Email, Subscribe To Record, Create Record, Go To Record actions. You can set the value of multiselect fields for new records with Set Field Value.

You can also complete the following other tasks with multiselect fields:

How do I set the value of a field based on the value a user set for another field?

Use the Set Field Value action to set the field value after a user edits a different field or set the field value after the user saves the record, depending on the trigger used with the Set Field Value action:

For more information, see Set Field Value Action.

Field names in SuiteFlow dropdown lists are sometimes different than the names of fields that appear in the UI. For example, a field called ‘Assigned’ in NetSuite may be called ‘Assigned To’ in SuiteFlow. How do I know if the fields are the same?

View the form customization page for the record that contains the field names. On the form customization page, the Description column lists the field names that appear in SuiteFlow, and the Label column lists the names that appear in NetSuite.

For example, to access the field names for a Task record:

  1. Go to Activities > Scheduling > Tasks > New.

  2. In the Customize dropdown list, select Customize Form.

  3. Click the Fields subtab.

    On the Custom Entry Form page, note the difference in the values between the Description column and the Label column for the Assigned field:

    A portion of the Custom Entry Form page that highlights the Assigned row. Users should note that in the Description column, it is listed as "Assigned," whereas in the Label column, it is described as "Assigned To."

Can I access sublists and sublist fields in a workflow?

No. Sublists and their fields are not accessible from a workflow. To manipulate a sublist in a workflow, create a custom action using a workflow action script. See N/workflow Module and Custom Action.

Questions About Buttons

The following FAQs describe issues related to buttons and SuiteFlow.

How do I use buttons to help users go to other records and pages in NetSuite?

Use the Add Button action with the Go To Page or Go To Record actions. See Using Buttons for Navigation.

How do I use buttons to transition the record in the workflow from one state to another?

Create the button with the Add Button action and then create a transition that executes on the click of the button. Approval routing workflows use this method to transition between states. See Using Buttons to Execute Transitions.

Why do the buttons I have added to the record disappear when I refresh the browser?

Verify the Add Button actions use the correct trigger for the Trigger On property. To properly add buttons to a record form, the trigger must almost always be Before Record Load.

If you use the Entry trigger for the Add Button action, the button is only added the first time a record enters a state. Any actions set to trigger on Entry do not execute again if the record is reloaded during the time that it is in a state. Consequently, the Add Button action executed the first time that the record entered the state, but did not execute again when the record was reloaded. Then the button disappeared.

Use this same guideline with the Remove Button action. Use Before Record Load to make sure that the buttons are always removed, regardless of when and how a user accesses the record during the time that the record is in a specific state.

How do I create a button that, when clicked, navigates users to other records or pages in NetSuite?

See Using Buttons for Navigation. If you want to transition the record in the workflow from one state to another based on a user clicking a button, see Using Buttons to Execute Transitions.

Questions About Reports

Can I generate reports to show which records are in a workflow and how long they have been in the workflow?

Yes. You can search for workflow definitions or workflow instances. Use a workflow search to get information such as which workflows are running, which workflows are inactive, which record types are used in workflows, which employees are using certain workflows, or which workflows came from a bundle installation. See Workflow Searches.

Questions About Errors

The following FAQs describe issues related to errors and SuiteFlow.

If an error occurs (through SuiteFlow or other means) on Before Record Submit, will the After Record Submit actions still be triggered?

No. If a system error occurs between the time a user clicks Save on a record and the time that the record is saved to the database, any action set to execute on the After Record Submit trigger does not execute.

Similarly, if a Return User Error action executes on a Before Record Submit trigger, then neither the After Record Submit actions or any unexecuted action on a Before Record Submit trigger do not execute until the user resolves the issues with the record.

What do the “Stack overflow on line <xxx>” or “Too much recursion” errors mean?

These errors occur due to an infinite loop in a workflow. An infinite loop occurs when one operation triggers another operation, and then the second operation triggers the first again.

For example, a workflow uses a Set Field Value action on an After Field Edit trigger and the Client Field property in the action definition equal to a specific field on the record. If a user edits the field set for the Client Field property, an infinite loop results as the action is continually executed.

An example of an infinite loop in a workflow is a workflow for a purchase order record. The Employee field on a purchase order is dependent on Vendor record, and the list is restricted to employees that belong to the vendor subsidiary. Consequently, the Employee field reloads when a vendor is selected. To avoid this type of infinite loop, set the Employee != Current User condition as a workflow condition.

Questions About Actions

The following FAQs describe issues related to actions and SuiteFlow.

Can I copy a workflow?

Yes. Use the Make Copy command, available from the More menu on the workflow definition page. See Copying a Workflow.

Can a workflow kick off another workflow?

Yes. Use the Initiate Workflow action to start another workflow from within a parent workflow. When the child workflow completes, the record transitions to the next state in the parent workflow. See Initiate Workflow Action.

How do I create a child workflow?

First, create the parent and child workflows. Then, in the parent workflow, use the Initiate Workflow action to initiate the child workflow. See Creating a Workflow and Initiate Workflow Action.

Can a workflow execute SuiteScript?

Yes. Create a workflow action script and then use a custom action to call the workflow action script. See SuiteScript 2.x Workflow Action Script Type and Custom Action.

Can workflows be bundled?

Yes. See Bundling a Workflow.

Can the workflow take some action if a record has been in a particular state too long, for example, if the business process is expired?

Yes. Set the Delay field on a transition. See Scheduling a Transition.

If I inactivate an action, will it also apply to records with currently active workflow instances?

Yes, if you inactivate an action, then the action no longer executes, even if an existing workflow instance is currently running.

Can I inactivate a transition?

No, you cannot inactivate a transition.

The Payment Method field on transactions isn't being set. What's wrong?

If a workflow based on the Cash Sale, Customer Deposit, or Customer Payment transaction record types needs to set the Payment Method field, make sure the Set Field Value action triggers on the Before User Edit client trigger, instead of the Before Record Load server trigger.

The sourcing of the Payment Method field from the customer overrides the default value set by a workflow. Use the Before User Edit trigger to allow all fields to be sourced before the Set Field Value action sets the value of the field.

How do I execute an action on records returned in a saved search?

Create a scheduled workflow to perform a saved search and initiate a workflow instance on each record returned by the saved search. See Scheduling a Workflow.

How do I send statements to customers?

For workflows with a base record type of Customer, use the Send Email action to send statements. For more information, see Attaching Statements to an Email and Attaching Transactions to an Email.

How do I send transactions in a workflow?

For workflows with a base record type of Customer, use the Send Email action to send other transactions. For more information, see Attaching Statements to an Email and Attaching Transactions to an Email.

When I use the Go To Record action in my workflow, why are some of the fields not automatically populated as expected?

If you create a workflow that includes a Go To Record action that sources some field values, the related fields on the new record might not populate automatically. For example, if you have a workflow that runs on the Task record and automatically populates the Vendor field on Purchase Order records (action A), the system should automatically set the subsidiary based on the subsidiary for the vendor (action B). If you use the Go To Record action in this workflow example, the Go To Record action completes action A but does not complete action B and the subsidiary field on the Purchase Order is left blank. This is a known behavior associated with the Before Record Load trigger of a new record.

To workaround this issue, you need to do the following:

  1. Create a custom List/Record field with Vendor set as the target record type. Apply this field to the Purchase order record. To avoid confusion, the custom field can be hidden.

  2. Create a new auxiliary workflow that executes on the Purchase order record with the On Create initiation type and the Before Record Load trigger.

  3. To populate the Vendor field on Purchase orders, including the subsidiary information, add the Set Field Value action to your workflow. Set the trigger to Before User Edit. If necessary, you can add conditions that determine when the subsidiary information is populated. The Set Field Value action should populate the Vendor field on Purchase Order with the value contained in the field we created in step 1.

  4. In your original workflow, edit the Go To Record action so that it populates the field you created in step 1, instead of populating the Vendor field directly.

Now, when the original workflow initiates the Go To Record action, the Vendor field and related fields will be populated automatically.

For more information, see Set Field Value Action.

In my approval routing workflow, why is my “next approver” not being set?

If employees use the Employee Center to access records in a workflow, issues with the Next Approver field may occur. Setting a Next Approver field requires workflow access to data from a related record, usually the Employee record type.

Most users do not have access to other employee records. Consequently, since the workflow runs with the current user permissions, the workflow cannot access the record types required to properly set the field value. This issue can occur with other record types, for examples, purchase orders.

To resolve this issue, you can enable the Execute As Admin property on the workflow definition page. This provides users access to all records in NetSuite and enables the Next Approver fields to be set accordingly.

For more information about this property, see Execute As Admin.

How do I create a time-based action? For example, how do I send an email two days after a record has entered a state in the workflow?

Use a delay on a transition to a state that contains a Send Email action or set a delay on the Send Email action itself. See Scheduling an Action, Scheduling a Transition, and Welcome Email Sent to Customers Three Days After First Order Workflow.

Questions About SuiteFlow Terminology

The following FAQs describe issues related to SuiteFlow terminology.

In SuiteFlow, is “user” the same thing as “employee?”

Yes. In SuiteFlow, the term user dynamically defines whoever performed the action that caused a workflow instance to initiate on a record. A user can be an employee, the employee’s supervisor, or any other user who performs the action in NetSuite that initiates a workflow instance.

For example, in one state of a workflow, the user might be the employee filling out a travel request. In another state, the user might be the employee's supervisor, who must open the travel request to approve or reject.

The following screenshot shows a Send Email action. In this example, the user in the From Field is the user who is currently working with the record, indicated by the Current Record value of the Record dropdown list.

A portion of the Send Email action showing the Parameters section settings. User is selected in the Field drop-down list, which is highlighted in the screenshot.

What does “Current Record” mean in SuiteFlow?

The Current Record value in the Workflow Manager represents the record in a workflow and the corresponding record values. For example, a user creates a purchase order record and a workflow instance initiates on the purchase order. Use the Current Record value to access the values of the purchase order properties in a workflow definition.

The value of the Current Record can change dynamically, depending on the user that accesses a record during the time that the record is in a workflow.

Send Email Action Example

The following screenshot shows a Send Email action for a purchase order. In the Sender and Recipient sections, the User and Supervisor values for Current Record represent the user currently accessing the purchase order record and the supervisor for that employee, respectively.

A portion of the Send Email action page for a purchase order. In the Sender and Recipient sections, the User and Supervisor values for Current Record represent the user currently accessing the purchase order and the supervisor for that employee, respectively.

Go To Record Action Example

You can also use the Current Record values to populate the fields in another record. For example, in a workflow for a Customer record, you use a Go To Record action to create a Customer Payment record. You can use the values on the current Customer record to populate the fields on the new record.

The following screenshot shows the Parameters section of a Go To Record action. The Customer (Payments and Deposits) field on the Customer Payment record is populated with the value of the Customer entity on the current record.

A portion of the Parameters section of a Go To Record action. The Customer (Payments and Deposits) field on the Customer Payment record is populated with the values of the Customer entity on the current record.

What is the trigger execution model in SuiteFlow?

For a complete discussion of the SuiteFlow trigger execution model, see the following topics:

Related Topics

General Notices