LoadFromFile(FileName: String);
FileName - a full name of the file, from which the container has to be loaded.
The LoadFromFile method loads the container from a file.
Executing the example requires the C:\Filter.xml file containing access protocol filter and the C:\Copy.xml file.
Add a link to the Metabase system assembly.
Sub UserProc;
Var
FilCon, FilConDef: IAuditFiltersContainer;
Begin
FilCon := New AuditFiltersContainer.Create;
FilCon.LoadFromFile("C:\Filter.xml");
FilConDef := New AuditFiltersContainer.Create;
FilConDef.Assign(FilCon);
FilConDef.SaveToFile("C:\Copy.xml");
End Sub UserProc;
After executing the example, the FilCon container is loaded from the file C:\Filter.xml and is copied to the FilConDef container. The FilConDef container is saved to the C:\Copy.xml file.
See also: