Home > Forum > Forms > How to check if a new comment has been entered to trigger something on path traversal afterwards?

How to check if a new comment has been entered to trigger something on path traversal afterwards?
0

Hi folks,

My goal is to send an email when a comment has been entered in a instance.
Sadly I have found no way to find out if there has been a new comment to trigger an email action on path traversal.

I hope someone can help out.

Best regards

Fabia

MVP
In reply to: Kuchling, Fabian (DCCS)

I was able to solve it by adding some JS (image) to the page, which adds an "onchange" event listener to the comment box element.

Then I was able to check if a new comment was made, so I was able to check via execution condition if a mail should be sent or not.

Best Regards

Hi Fabian,

interesting idea. I will remember this for another use case. :)

I would have gone done another road. I would have tested to get the current/previous comments from the history and compare the string.

SELECT [WFH_ID]
,[WFH_OrgID]
,[WFH_Description]
, [WFH_Version]
FROM [dbo].[WFHistoryElements]
where WFH_OrgID = 12371
order by [WFH_ID] desc

Best regards,
Daniel