CreateUpdatedXml() public method

public CreateUpdatedXml ( IViewSettings settings ) : string
settings IViewSettings
return string
Exemplo n.º 1
0
 //-----
 // modify functionality (below) is only for the settings dialog save functionality
 //-----
 public static void Modify(string xmlFile, ViewSettings viewSettings)
 {
     string xmlUpdated;
     using (var stream = new StreamReader(xmlFile))
     {
         var parser = new ViewSettingsParser(stream);
         xmlUpdated = parser.CreateUpdatedXml(viewSettings);
     }
     using (var stream = new StreamWriter(xmlFile))
     {
         stream.Write(xmlUpdated);
     }
 }
Exemplo n.º 2
0
        //-----
        // modify functionality (below) is only for the settings dialog save functionality
        //-----

        public static void Modify(string xmlFile, ViewSettings viewSettings)
        {
            string xmlUpdated;

            using (var stream = new StreamReader(xmlFile))
            {
                var parser = new ViewSettingsParser(stream);
                xmlUpdated = parser.CreateUpdatedXml(viewSettings);
            }
            using (var stream = new StreamWriter(xmlFile))
            {
                stream.Write(xmlUpdated);
            }
        }