You are here

getVersion

getVersion(label) gets a specific version of a document identified by label.

Parameters

label
The version label of the node to get.

Returns

A ScriptVersion object representing the version of this node requested.

Example

    var version;
    var createdDate;
    var creator;
    
    var node = companyhome.childByNamePath("TEST_FILE_1.TXT");

    if (node.isVersioned){
        version = node.getVersion("1.0");
        createdDate = version.createdDate;
        creator = version.creator;          
    }
       

Sending feedback to the Alfresco documentation team

You don't appear to have JavaScript enabled in your browser. With JavaScript enabled, you can provide feedback to us using our simple form. Here are some instructions on how to enable JavaScript in your web browser.