SaveToFileNF(FileName: String);
SaveToFileNF(FileName: System.String);
FileName. Full path and file name, to which the update is saved.
The SaveToFileNF method saves an update to a file with the *.pefx extension.
The *.pefx format enables to save bigger number of objects to the update, comparing with the *.pef format.
To execute the example, add a link to the Metabase system assembly. The repository must contain an object with the MyOBJ1 identifier.
Sub UserProc;
Var
Mb: IMetabase;
MUpdate: IMetabaseUpdate;
RootFolder: IMetabaseUpdateFolderNode;
Node: IMetabaseUpdateObjectNode;
Begin
Mb := MetabaseClass.Active;
MUpdate := Mb.CreateUpdate;
RootFolder := MUpdate.RootFolder;
Node := RootFolder.Add(MetabaseUpdateNodeType.Object) As IMetabaseUpdateObjectNode;
Node.UpdatePart := MetabaseObjectUpdatePart.DataMetadataSD;
Node.UpdateType := MetabaseObjectUpdateType.Simple;
Node.IncludeChildrenDependencies := TriState.OnOption;
Node.Object := Mb.ItemById("MyOBJ1").Bind;
MUpdate.SaveToFileNF("C:\Update.pefx");
End Sub UserProc;
After executing the example an update is created and is saved to the specified file.
To execute the example, add a link to the ForeSystem system assembly. The repository must contain an object with the MyOBJ1 identifier. The specified procedure is an entry point for the .NET assembly.
Public Shared Sub Main(Params: StartParams);
Var
MB: IMetabase;
MUpdate: IMetabaseUpdate;
RootFolder: IMetabaseUpdateFolderNode;
Node: IMetabaseUpdateObjectNode;
Begin
MB := Params.Metabase;
MUpdate := Mb.CreateUpdate();
RootFolder := MUpdate.RootFolder;
Node := RootFolder.Add(MetabaseUpdateNodeType.untObject) As IMetabaseUpdateObjectNode;
Node.UpdatePart := MetabaseObjectUpdatePart.moupDataMetadataSD;
Node.UpdateType := MetabaseObjectUpdateType.moutSimple;
Node.IncludeChildrenDependencies := TriState.tsOnOption;
Node.Object := Mb.ItemById["MyOBJ1"].Bind;
MUpdate.SaveToFileNF("C:\" + "Update.pefx");
End Sub;
After executing the example an update is created and is saved to the specified file.
See also: