Click or drag to resize
OpenDocument Method

Open an Office document online.

Syntax

[ JavaScript ]

document.getElementById("AceoffixCtrl1").OpenDocument(String DocumentURL, int OpenMode, String UserName)

Parameters

DocumentURL

[in] String type. The URL of the document which is going to be opened.

OpenMode

[in] String type. The work mode AceoffixCtrl should use after the document is opened. Make sure that the OpenMode is consistent with the file type of the document.

UserName

[in] String type. The operator of the current document. Typically, UserName should be the name of current user who has logged in your web application.

Return Value
No return value.
Remarks

This is the important method of AceoffixCtrl. It is used to open an Office document online.

The remarks of this method are the same as the remarks of the Aceoffix.AceoffixCtrl.OpenDocument method at server-side. The difference is that you can call it on client-side.

The definition of OpenMode parameter is the same as the AceoffixOpenModeType. But this OpenMode parameter uses a string type. Its usage refers to the following code example.

Example
JavaScript
document.getElementById("AceoffixCtrl1").OpenDocument("doc/test.doc", "docNormalEdit", "John Scott");
See Also