Method Catch
- Namespace
- DotNetBrowser.Js
- Assembly
- DotNetBrowser.dll
Catch(Action<object>)
Appends the rejection handler to the promise.
IJsPromise Catch(Action<object> onRejected)
Parameters
Returns
- IJsPromise
A new IJsPromise resolving to the return value of the called handler, or to its original settled value if the promise was not handled.
Exceptions
- JsException
The JavaScript function raised an exception.
- ObjectDisposedException
The IJsPromise has already been disposed.
- ConnectionClosedException
The connection to the Chromium engine is closed.
Catch(Func<object, object>)
Appends the rejection handler to the promise.
IJsPromise Catch(Func<object, object> onRejected)
Parameters
Returns
- IJsPromise
A new IJsPromise resolving to the return value of the called handler, or to its original settled value if the promise was not handled.
Exceptions
- JsException
The JavaScript function raised an exception.
- ObjectDisposedException
The IJsPromise has already been disposed.
- ConnectionClosedException
The connection to the Chromium engine is closed.