OpenFileDialog openFileDialog = new OpenFileDialog();
openFileDialog.InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.Desktop);
DialogResult dr = openFileDialog.ShowDialog();
打开一个文件选择对话框,默认路径为桌面。
OpenFileDialog openFileDialog = new OpenFileDialog();
openFileDialog.InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.Desktop);
DialogResult dr = openFileDialog.ShowDialog();
打开一个文件选择对话框,默认路径为桌面。
转载于:https://www.cnblogs.com/xiaoqian180703/p/9259269.html