WorkbookView.ViewMode

Syntax

ViewMode: Boolean;

Description

The ViewMode property determines whether workbook is in edit mode.

Comments:

If this property is True the workbook is in view mode, when the property is False, the workbook is in edit mode.

Example

To execute the example, the page must contain the WorkbookBox component named workbookBox (see Example of Creating the WorkbookBox Component), and also add the following code in the handler, that processes document opening event:

//determine whether workbook is in the edit mode
if (workbookBox.getViewMode() == True)
	console.log("Workbook is in the view mode");
else
	console.log("Workbook is in the edit mode");

After executing the example the browser console displays the message "Workbook is in edit mode" if it is in edit mode, or "Workbook is in view mode" if the workbook is currently open in view mode.

See also:

WorkbookView