Create a Stored Procedure Success Message
When setting up a custom button that triggers a stored procedure, you can set up the stored procedure to return a success or failure message without raising an exception from the stored procedure, triggering a stack trace error.
- Add a parameter to a stored procedure named @ReturnMessage that is an output parameter.
- Code the stored procedure to set the return message. If the message should not display, set it up as an empty string.
- Code the stored procedure to return an integer to determine whether the message is a success message (0) or failure message (any number greater than 0).
- When setting up the custom button in the VA Custom Form Buttons Form, add the return message parameter to the Parameters tab.