Document

A Document object is passed on the onruncompleted callback. The object offers two methods: one is to retrieve the content of the document, and the other to update it.

The GetContent method accepts one callback parameter:

  • callback. Function(format, content). This method is called once the content of the document is retrieved from the server. The format parameter contains the format of the result document (.doc, .docx, or .pdf). The content attribute contains the actual content (base64 encoded).

The SetContent method accepts the content as its only parameter:

  • content. Base64 string. The content that is uploaded to the server to replace the currently stored content of the document.