Ejemplo n.º 1
0
 public void Save()
 {
     if (State == FileState.OK)
     {
         if (type == TypeFile.txt)
         {
             File.WriteAllText(Path, file.ToString());
         }
         else
         {
             File.WriteAllBytes(Path, DVPL.ToDVPL(file.ToString()));
         }
     }
 }
Ejemplo n.º 2
0
 public void SaveAs(string path)
 {
     if (State == FileState.OK)
     {
         if (System.IO.Path.GetExtension(path) == "dvpl")
         {
             File.WriteAllBytes(path, DVPL.ToDVPL(file.ToString()));
         }
         else
         {
             File.WriteAllText(path, file.ToString());
         }
         Path = path;
     }
 }