Call Script action in Business Rule
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-27-2019 09:39 AM
Hii All,
I created the script action and tried to call into Business Rule. It doesnt working. The following condition i used.
1. Event has created
2. Wrote the script in Script action and mapped with Event.
3. Called the script action into Business Rule.
When to Run
When - After, Order - 111, Insert and update, Condition - Attachment count changes and Supplier Ref is not empty.
I tried to execute and it's not working. I have used script from script action in Business Rule -attachment count value is updating. Could you please explain why this issue is happening
Regards,
Suresh Loganathan.
Suresh.
- Labels:
-
Incident Management

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-27-2019 09:43 AM
Can you make the business rule async and remove the when from the gs.eventQueueScheduled and change it to gs.everQueue() and try again,
Please mark this response as correct or helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-27-2019 11:43 AM
Everything looks good. May be your Business Rules is not firing. Can you put in Log statements in your Business Rule and check if they appear. Also, put log statements in your script action. You scheduled your event to fire after 2 minutes, so check the logs for script action after 2 minutes.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-29-2019 03:25 AM
Issue has been fixed. It was happen due to event name. We should use . symbol when we are giving space in Script Action name. ie., "Test Data" we should name it as "Test.Data"
Suresh.