/// <summary> /// Update the ViewModels, substract the defaultSchema from the configuration then save the file to disk. /// </summary> /// <param name="appVM">In-memory application view model.</param> /// <param name="defaultSchema">Schema of the plain old database.</param> public static void Save(this ApplicationViewModel appVM, AppMetadata defaultSchema, string path) { var proj = new ProjectContainer(); proj.Name = appVM.Name; proj.ConnectionStrings = CreateConnectionStrings(appVM.Connections.Connections); proj.Templates = CreateTemplates(appVM.Templates.ServerModifiers, defaultSchema); proj.Save(path); }
public async void SaveLoadConfigFile() { const string fileName = "dcSaveLoadConfigFile.config"; _proj.Save(fileName); var configLoaded = await ProjectContainer.LoadAsync(fileName); //var temp = _config.SerializeXml(); File.Delete(fileName); }