Пример #1
0
        private bool SaveFile(string title, string file)
        {
            try {
                Win.Title = title;
                _fileName = file;
                System.IO.File.WriteAllText(_fileName, _textView.Text.ToString());
                _originalText = _textView.Text.ToByteArray();
                _saved        = true;
                _textView.ClearHistoryChanges();
                MessageBox.Query("Save File", "File was successfully saved.", "Ok");
            } catch (Exception ex) {
                MessageBox.ErrorQuery("Error", ex.Message, "Ok");
                return(false);
            }

            return(true);
        }