This method freezes the current RepositoryObjectVersion object.
Call object.FreezeVersion
The FreezeVersion method syntax has the following parts.
Part | Description |
Object | An object expression that evaluates to a RepositoryObjectVersion object. |
The object version must be unfrozen.
After you freeze an object version, you cannot change its non-annotational property values. However, you can change the value of any of its annotational properties.
After you freeze an object version, you cannot enlarge or shrink or resequence any of its origin collections. Furthermore, you cannot change any of the individual versioned relationships in any of the origin collections. That is, you cannot enlarge or shrink an origin versioned relationship's TargetVersions collection; you cannot pin or unpin a target object version; and you change the name by which the origin object version refers to the target object.
If you call this method for an item currently checked out to any workspace (including the workspace in which you are working), it returns an error.
If the to-be-frozen object version includes any non-null origin collection whose corresponding collection type has the COLLECTION_REQUIRESFREEZE flag set, and that non-null collection includes an item whose TargetVersions collection contains a non-frozen object version, the method fails.