我已经可以打开保存文件对话框,但是当我运行程序并尝试保存它时,它可以打开,但文件不存在。这是为什么?这是代码:
_saved = false;
SaveFileDialog saveFileDialog1 = new SaveFileDialog();
saveFileDialog1.Filter = "System File (*.pos) | *.pos";
saveFileDialog1.Title = "Save File As";
saveFileDialog1.ShowDialog();
if (_saved)
{
this.Text = "Database - " + saveFileDialog1.FileName + "";
_filename = saveFileDialog1.FileName;
}
else
{
this.Text = this.Text;
}
谢谢你,我很感激你的帮助。