ShowError
Shows an error/warning message.
Syntax
expression.ShowError(error, level);
expression - A variable that represents a Api class.
Parameters
| Name | Required/Optional | Data type | Default | Description |
|---|---|---|---|---|
| error | Required | string | The error text. | |
| level | Required | number | -1 or 0 for error or warning. |
Returns
This method doesn't return any data.
Example
const text = 'Message you want to show';
const level = 0; // Warning, not an error
Asc.plugin.executeMethod('ShowError', [text, level]);