Is it possible to prevent WPF CommandManager from executing with CanExecute delegates?
I have an Unhandled Exception Handler procedure that displays an error window for the user. I have a situation when the exception is thrown as part of the CanExecute chain. This calls the exception handler, which displays the window. At this point, the CommandManager launches and requests CanExecute, throwing another exception, calling the handler, showing another window, asking for CanExecute, throwing another exception ... etc. Etc. Etc.
I somehow need to prevent this CanExecute repetition. I tried to simply ignore subsequent errors in the handler, but this means that the exception information in the error window is empty.
source
share