diff --git a/src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Internal/ManagedCallback.cs b/src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Internal/ManagedCallback.cs index 68f690050b..5724a59b2f 100644 --- a/src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Internal/ManagedCallback.cs +++ b/src/AddIns/Misc/Debugger/Debugger.Core/Project/Src/Internal/ManagedCallback.cs @@ -276,7 +276,10 @@ namespace Debugger "Project -> Project Options -> Compiling -> Target CPU = 32-bit Intel"; } - System.Windows.Forms.MessageBox.Show(errorText); + if (Environment.UserInteractive) + System.Windows.Forms.MessageBox.Show(errorText); + else + throw new DebuggerException(errorText); try { pauseOnNextExit = true;