Persistate API documentation
SaveVersion Method (sourceFile)
NamespacesPersistateUtlSaveVersion(String)

[This is preliminary documentation and is subject to change.]

Saves a numbered version of a file.
Declaration Syntax
C#
public static void SaveVersion(
	string sourceFile
)
Parameters
sourceFile (String)
The full path of the source file to copy. If this doesn't exist, no action is taken and no exception is thrown.
Remarks

This method saves a copy of a file in a folder called "versions" which is under the folder containing the file. The copy has the same name as the original, but with "_nnn" appended to the file name, before the extension. nnn is a sequence number which is assigned as one more than any existing copies in the versions folder.

For example, assuming that versions up to 21 exist, the file c:\project1\sources\myclass.cs will be copied to c:\project1\sources\versions\myclass22.cs If the current latest version of the file in the versions folder is identical to the source file, then no new version is saved.

Assembly: Persistate (Module: Persistate) Version: 0.6.1.20 (0.6.1.20)