Exemplo n.º 1
0
 private void Save()
 {
     saveFileDialog1.FileName         = tabControl1.SelectedTab.Name;
     saveFileDialog1.InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
     saveFileDialog1.Filter           = "RTF|*.rtf"; saveFileDialog1.Title = "Save";
     if (saveFileDialog1.ShowDialog() == System.Windows.Forms.DialogResult.OK)
     {
         if (saveFileDialog1.FileName.Length > 0)
         {
             GetCurrentDocument.SaveFile(saveFileDialog1.FileName, RichTextBoxStreamType.RichText);
         }
     }
 }
Exemplo n.º 2
0
 private void SaveAs()
 {
     saveFileDialog1.FileName         = tabControl1.SelectedTab.Name;
     saveFileDialog1.InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
     saveFileDialog1.Filter           = "Text Files|*.txt|VB Files|*.vb|C# Files|*.cs|All Files|*.*";
     saveFileDialog1.Title            = "Save As";
     if (saveFileDialog1.ShowDialog() == System.Windows.Forms.DialogResult.OK)
     {
         if (saveFileDialog1.FileName.Length > 0)
         {
             GetCurrentDocument.SaveFile(saveFileDialog1.FileName, RichTextBoxStreamType.PlainText);
         }
     }
 }
Exemplo n.º 3
0
 private void SaveAs()
 {
     if (tabControl1.TabPages.Count > 0)
     {
         saveFileDialog1.FileName         = tabControl1.SelectedTab.Name;
         saveFileDialog1.InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
         saveFileDialog1.Filter           = "Text Files|*.txt|C# dosyası|*.cs|Tüm Dosyalar|*.*";
         saveFileDialog1.Title            = "Farklı Kaydet";
         if (saveFileDialog1.ShowDialog() == System.Windows.Forms.DialogResult.OK)
         {
             if (saveFileDialog1.FileName.Length > 0)
             {
                 GetCurrentDocument.SaveFile(saveFileDialog1.FileName, RichTextBoxStreamType.PlainText);
             }
         }
     }
 }