You need to sign in to do that
Don't have an account?
ethanone
Halt Controller Operation Gracefully
I'm writing a page button controller that basically does a customized clone operation. I want the controller to check to see if the Opportunity stage is closed. If it is not, i need the controller to display an error on the screen and send the user back to the view page. What is the best way to go about this?
Thanks in advance.
Thanks in advance.
Craig Warheit
Check to see if the Opportunity is closed, and if it's not, create an error message and return null.
ethanone
Thanks, I've found that this snippet cannot go in the contructor (can't return anything from the construtor). Should this have its own method? Where is the best place to put this?