04-03-2019 09:13 AM
Which implementations are able to display message boxes? I have a custom action that executes on a Unity Form, and found an edge case where I need to notify the user to take an action outside of OnBase. I attempted using the MessageBox with the OnCustomActionExecuteAction script, but received this error:
Showing a modal dialog box or form when the application is not running in UserInteractive mode is not a valid operation. Specify the ServiceNotification or DefaultDesktopOnly style to display a notification from a service application.
Any ideas on how I can deliver this message to the user from this Unity Form?
Thanks!
John
04-03-2019 09:24 AM
Hey John --
Unity Form scripts are server-side so the dialog box would pop up in the execution environment (the server) which is why we disallow it on server scripts (all scripts that don't explicitly call themselves Client scripts). What you might do is create a custom action that hides or unhides a readonly text field that instructs the user on what they must do in order to continue on with the script, or something of that nature.
04-03-2019 10:26 AM
Hi Adam, I like that idea. I'll add something that notifies them when the situation occurs. Thanks!
04-05-2019 09:08 AM
Hey Adam,
I've found the methods to get if a field is visible/editable, but is there a method within CreateUnityFormModifier or on the Form objects that allow you to toggle the element visibility? I've searched the SDK models and I don't think I see one.
I guess this could be accomplished by having custom actions that hide the text when it's empty, and display when it's filled, and within my script I can clear the content out.
That kind of brings me to another question: Can I use the Paragraph Control to accomplish this, or should I only use the Text Box control, set to read only?
04-05-2019 09:20 AM
Hi John --
What I'd envisioned was a custom action as per your second paragraph -- there's no way to hide a control on a Unity Form from the API, unfortunately. I don't see why you wouldn't be able to use the Paragraph control for this, though.
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.