Articles in this section
Category / Section

8.2 Automatic email notifications with PDF reports and form links

Published:
Updated:

Zegeba provides a wide selection of methods of automatic reporting per email notification.

After data has been captured in a form, a notification can be sent by email to relevant contacts. This can happen whether the form data capture is completed, approved, edited or just created.

The email may consist of:

– static text, for instance informing about a certain check having been performed successfully, and/or

– some of the captured data, for instance a quantity measured during a check, and/or

– access to the view the entire data capture as a PDF file attachment, and/or

– access to the edit the entire data capture as a form link that can be opened in a browser



Setting up a notification email message

  1. In the Designer, select the top Form element and go to the Other tab in Element Properties.

821.png

  1. Select Enable Email Notifications – see illustration above.
  2. In Notify when, select when you want to send emails, when form is created, changed og its state is changed.
  3. In Notify for Form States, choose between Always, Complete, Approved, Edited, Created, Created or Edited or any custom states set up specifically for your company.

822.png

  1. Type a Subject for the email. You can type a static text and/or use description formulas to fill in an actual value from the data capture. See the syntax in Designing: 6.4 Description Formula.
  2. Type a Message for the email. Enter a static text and/or use element codes to fill in actual values from the data capture.
  3. Type in one or more main Email recipients. Separate addresses with a semicolon (;) and no spaces in between.
    – or –
    Create in the form design a list of email recipients the user can choose from, either as a Single Select element with a drop-down list or radio buttons, or a Multiple Select element with one check box for each potential recipient. Let the labels of the Single/Multiple Select’s Option elements show the actual email address, such as support@zegeba.com, not the option’s ID (in that case support_zegeba_com).
    – or –
    Create in the form design a Text Area element where the user can type in one or more email addresses separated by semicolon. Note that this poses a risk for the mail being sent to the wrong person.

In the example illustrated above, we have included as email recipients the addresses the users enter in the Text Area element with ID send_mail_to.

  1. If you want some people to receive a CC copy (Carbon Copy) of the mail, type in the email addresses, or the description formula, of the these in CC recipients. These addresses will be entered in the mail’s CC field and are visible to all recipients.
  2. Similarly you can enter email addresses in the BCC recipients (blind copy) field. Other recipients will not see these names at all.
  3. Select Include Link to data to put the filled form’s URL address in the email message. Note that the recipient must have the right user privileges on the Zegeba server to be able to access these data. See more information on user roles in Managing: 3.3 User roles.
    – and/or –
  4. Select Include PDF as attachment in email to send the filled-in form as a PDF file attachment to the email.

Note: The file name of the PDF will be the same as the Description formula set in the main Form element, see Designing: 6.4 Description Formula. Also, if you have deactivated or deleted the user called Admin, the PDF will not be attached to the email.

You can only make one “recipe” on what to send per form – Subject, Message, link, PDF attachment. You can choose to send only specific pages in the PDF by setting the unwanted pages to Hide on PDF (see 4.2.4 PDF tab). This will however cause the page to be excluded from all PDFs you generate, not just the ones sent through email notifications.

See also 8.3 Security considerations when emailing information on data captured.



Setting up different email recipients for different form states

From Zegeba v 4.0, there is a new function iif that you can use to send emails to different recipients based on the form state. The function gives one result if its premise is true, another result if the premise is false. In the example below, the email will go to iscompleted.person if the form state contains the word Complete. For all other form states, the email goes to inprogress.person1 and inprogress.person2.

823.png

The iif function is a calculation entered in a hidden text Input element called for instance email_recipients, and this element must be entered in Email recipients as {#email_recipients}.

The function can be nested to allow for more than two groups of recipients and form states.

Contact Zegeba Support if you want help with setting this up.

Was this article useful?
yes
No
Help us improve this page
Please provide feedback or comments
Access denied
Access denied