officefileapi-devexpress-dot-xtraspreadsheet-dot-spreadsheetunhandledexceptioneventargs-24f26791.md
Gets the exception which triggers the UnhandledException event.
Namespace : DevExpress.XtraSpreadsheet
Assembly : DevExpress.Spreadsheet.v25.2.Core.dll
NuGet Package : DevExpress.Spreadsheet.Core
public Exception Exception { get; }
Public ReadOnly Property Exception As Exception
| Type | Description |
|---|---|
| Exception |
An Exception object representing an exception which caused the event.
|
Use the Exception property to get information on the exception not handled by the SpreadsheetControl.
The following code snippets (auto-collected from DevExpress Examples) contain references to the Exception property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
winforms-spreadsheet-create-custom-progress-indicator/CS/SpreadsheetProgressSample/Form1.cs#L58
// that is thrown when a user cancels the operation.
if (e.Exception is OperationCanceledException)
e.Handled = true;
// that is thrown when a user cancels the operation.
if (e.Exception is OperationCanceledException)
e.Handled = true;
winforms-spreadsheet-create-custom-progress-indicator/VB/SpreadsheetProgressSample/Form1.vb#L61
' that is thrown when a user cancels the operation.
If TypeOf e.Exception Is OperationCanceledException Then
e.Handled = True
' that is thrown when a user cancels the operation.
If TypeOf e.Exception Is OperationCanceledException Then
e.Handled = True
See Also
SpreadsheetUnhandledExceptionEventArgs Class