示例#1
0
 public static bool SSave(MapSet mapSet)
 {
     if (String.IsNullOrEmpty(mapSet.Path))
     {
         return(SSaveAs(mapSet));
     }
     else
     {
         return(mapSet.Save());
     }
 }
示例#2
0
        public static bool SSaveAs(MapSet mapSet)
        {
            SaveFileDialog saveFileDialog1 = new SaveFileDialog();

            saveFileDialog1.Filter = "Mapset|*.xml";
            saveFileDialog1.Title  = "Save Mapset";
            saveFileDialog1.ShowDialog();

            // If the file name is not an empty string open it for saving.
            if (saveFileDialog1.FileName != "")
            {
                return(mapSet.Save(saveFileDialog1.FileName));
            }

            return(false);
        }