action.skip

How to set a default BCC email address?

← PDF and Email FAQ

Your business may require to send copies of the invoice email to specific recipients – your sales department or the accounting division, for example. To this end, you pre-populate the Email BCC field of invoices.

There are, basically, two ways to do so:

Using ON Field

The ON field mechanism is the "JustOn way" for setting certain fields. To pre-populate the invoice Email BCC field, you add the custom field ON_EmailBCC to the source record for the invoice – if you create invoices from subscriptions, to the subscription, and in case of the generic invoice run, to the relevant source object.

  1. Navigate to the fields list of the relevant object.
  2. Create the following new field.

    Field Label API Name Data Type
    Email BCC ON_EmailBCC Formula (Text)

    For help about creating fields, see Managing Object Fields.

    Depending on your requirements, you can use a formula that directly specifies one or more addresses or one that chooses an address based on specific criteria. Once set, JustOn copies the value to the invoice Email BCC field upon invoice creation via invoice run.

Using Flow

Alternatively, you can use a dedicated Salesforce flow to have the invoice Email BCC field set on invoice creation.

  1. Click to enter Setup, then navigate to Process Automation > Flows.
  2. Click New Flow.
  3. Select Record-Triggered Flow and click Create.

    The minimum required flow elements include:

    Flow Element Option Value
    Start Object Invoice
    Trigger A record is created
    Optimize for Fast Field Updates
    Update Records How to Find Records to Update Use the invoice record that triggered the flow
    Filter Conditions None--Always Update Record
    Field ONB2__EmailBCC__c
    Value email address, enclosed in double quotes
    or
    variable to determine the required email address

    Specify node labels and API names as required.

    Depending on your use case, the flow setup will vary. You may need, for example, start node conditions or a decision node to determine whether to set the Email BCC field.

  4. Click Save.

    Specify a flow label and API name as required.

  5. Click Activate.

    This makes Salesforce trigger the flow when an invoice record is created, setting the Email BCC field based on your conditions.