I have an action button that edits 3 fields (...

I have an action button that edits 3 fields (which results in 3 changes that need to be synced), and a workflow that sends an email when the value in one of columns changes. I use the ThisColum.Before and ThisColumn.After to check if it has changed.

The issues is that the workflow is sending 3 emails out for each of the values being changed, but I only need one email to go out. My users are complaining about the multiple emails. Can someone please help me to fix it so only one email gets sent by the workflow?

The workflow rule is: [_THISROW_BEFORE].[Approved]<>[_THISROW_AFTER].[Approved]

0 7 743
7 REPLIES 7

Hey Aleksi,

Thanks for the quick reply. Iโ€™m not sure if that will help. Let me elaborate on whatโ€™s going on with my app.

This particular app is a TimeClock app that a supervisor uses to approve times for employees. The action button changes the following fields:

[Approved By] = USERNAME() [Approved Date] = TODAY() [Approved] = โ€œYesโ€

When the action button gets clicked, it automatically updates these three fields to the values I listed above.

The workflow looks to see the [Approved] column has changed from โ€œโ€ to โ€œYesโ€. However, for some reason, it is sending three e-mails. Iโ€™m guessing the other two fields being changed are somehow triggering the workflow to execute. I am having trouble figuring out how to make it only execute for the change in the [Approved] column.

Combine these three columns with one virtual column and use that in your workflow rule. Another workaround is using the counter or one workflow rule likeโ€ฆ

OR([_THISROW_BEFORE].[Approved]<>[_THISROW_AFTER].[Approved],[_THISROW_BEFORE].[ColumnB]<>[_THISROW_AFTER].[ColumnB])

The reason is thisโ€ฆ First two actions fire the workflow because the [APPROVED] field is blank before the 3th action. When the evaluation [APPROVED]<>[APPROVED] is fired and both values are blank, the evaluation is TRUE. This is reported issue and Appsheet is trying to fix this.

If you add another evaluation like ISNOTBLANK([APPROVED]) into your workflow rule, it wonโ€™t fire more than once.

Ahh! Genius workaround, the ISNOTBLANK solution should work perfectly. Iโ€™ll implement and let you know how it goes. Thanks!!

@Aleksi_Alkio

Aleksi is correct. as always.

I have updated the documentation to reflect this limitation. See topic โ€œSending Email When a Row is Updated to Have Specific Valuesโ€ in this article help.appsheet.com - Triggering Email, SMS, or Notifications from the App

We hope to change the behavior, but there are compatibility issue if we do this.

Triggering Email, SMS, or Notifications from the App help.appsheet.com

Aleksi always comes through with great solutions and in a timely fashion! Thanks again! It worked flawlessly!!

Youโ€™re welcome

Top Labels in this Space