Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview

Document Document myDocument.Unpublish()

Document Document myDocument.Unpublish(folderPath: string)

...

string folderPath
Path of folder(s)

Remarks

This method changes Document.State property to "Draft" and saves document.

If folderPath is specified, document is removed from specified folders. Path can be specified as full path. Non existing folders are ignored.

...

Code Block
languagejs
var existingDocument = $Documents.Get(id);

// Unpublishing the document under Test\Documents folder path:
existingDocument.Unpublish('Test\Documents');

Examples

...

languagejs

...

See Also