If it possible to perform a Show Message action on...
# suiteflow
r
If it possible to perform a Show Message action on load of a View of a record? I have what you would think the appropriate event (All Event Types) and trigger type (Before Record Load). The condition is based on a Contains of a custom field. It works for loading of the edit.
s
beforeLoad UE has the
form
passed in as a parameter. You would use:
form.addPageInitMessage()
Also make sure you’re filtering down to the context you want..
scriptContext.type === scriptContext.UserEventType.VIEW
r
Hey Sean - good to see you again (from my brief SCS tenure). We're trying to avoid utilizing a script on this one if possible, but I'm guessing it might be the route to go. Unless there's a way to do it with the workflow tools.
s
AH, I am now seeing this is for a workflow.. ~~ hmm… it may not run these on beforeload for VIEW.. Can you create a separate workflow to test the VIEW page message?
m
I think the Show Message action is only for Client Triggers. (per this documentation)
The Before Load is a server trigger
message has been deleted
message has been deleted
You can use the Return User Error action Before Record Load
r
Great insight. Thank you so much MGBC.
Unfortunately, a user error won't work since it takes the user back to the list of credit memos vs allowing them to proceed when opening one. Looks like a user event script is the only way.
m
Would the before user edit trigger work?
or does it have to be on View?