Esempio n. 1
0
 protected override void SaveChanges()
 {
     XmlStream.Position = 0;
     XmlStream.SetLength(0);
     base.SaveChanges();
     XmlStream.Flush();
 }
Esempio n. 2
0
 protected virtual void SaveChanges()
 {
     DataSet.AcceptChanges();
     if (CanWriteStream)
     {
         XmlStream.Flush();
         DataSet.WriteXml(XmlStream, XmlWriteMode.IgnoreSchema);
     }
     else
     {
         throw new ApplicationException("Can't write to XML stream.");
     }
 }