SaveToFile(FileName: String);
FileName - a file into which the list of repository objects and their calculated checksums will be saved.
The SaveToFile method saves the list of repository objects and calculated checksums to the file.
Executing the example requires that the repository contains an object with the Folder_1 identifier.
Sub Main;
Var
MB: IMetabase;
CheckList: IMetabaseCheckList;
MObj, MObj1: IMetabaseObjectDescriptor;
Begin
MB := MetabaseClass.Active;
CheckList := MB.CreateCheckList;
MObj := MB.ItemById("Folder_1");
CheckList.Add(MObj);
For Each MObj1 In MObj.Children Do
CheckList.Add(MObj1);
End For;
CheckList.SaveToFile("c:\control.crc");
End Sub Main;
After executing the example a list for calculating checksums of objects is created. The Folder_1 object and all its child objects, if there are such, are added to this list. After calculation the checksums are saved into the file c:\control.crc.
See also: