void WriteFile(string path, string filename) { string f; f = FileBrowserHelpers.CreateFileInDirectory(path, filename + ".waterline"); Designer.SaveToString(); FileBrowserHelpers.WriteTextToFile(f, Designer.PGdata); f = FileBrowserHelpers.CreateFileInDirectory(path, filename + ".png"); byte[] bt = Designer.MakeThumbBytes(512); FileBrowserHelpers.WriteBytesToFile(f, bt); }