TSaveDialog/zh CN
From Lazarus wiki
Jump to navigationJump to searchThe printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
│
English (en) │
français (fr) │
русский (ru) │
中文(中国大陆) (zh_CN) │
TSaveDialog 是保存文件的对话框. 控件在 Dialogs tab 的 Component Palette.
此控件为不可见控件,拖放到 form 窗体,然后使用方法 .Execute() 调用.
procedure TForm1.Button1Click(Sender: TObject);
var
myfPath: string;
begin
try
try
SaveDialog1.Execute;
myfPath := SaveDialog1.FileName;
Memo1.Lines.SaveToFile(myfPath);
Exit;
except
ShowMessage('程序异常,请重新保存');
end;
finally
//无论如何都会执行
ShowMessage('me');
end;
end;
参考资料