diff options
author | Sergey Chebotar <s.chebotar@gmail.com> | 2021-12-22 17:07:37 +0300 |
---|---|---|
committer | Sergey Chebotar <s.chebotar@gmail.com> | 2021-12-22 17:07:37 +0300 |
commit | ce5597d042062c820288c63b4e571ee77ac23ab0 (patch) | |
tree | 9400511fce89ae4b6d4df205b605f560778dcb57 /Source/AddIn/FileDialog.cs | |
parent | f97d344f39c46b5e2f883765e8859e78007a11b0 (diff) |
RegistryUtil and some fixes
Diffstat (limited to 'Source/AddIn/FileDialog.cs')
-rw-r--r-- | Source/AddIn/FileDialog.cs | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Source/AddIn/FileDialog.cs b/Source/AddIn/FileDialog.cs new file mode 100644 index 0000000..a7e2144 --- /dev/null +++ b/Source/AddIn/FileDialog.cs @@ -0,0 +1,24 @@ +using System.Windows.Forms; + +namespace RehauSku +{ + static class FileDialog + { + public static string GetFilePath() + { + string filePath = string.Empty; + + using (OpenFileDialog dialog = new OpenFileDialog()) + { + dialog.Filter = "Все файлы (*.*)|*.*"; + + if (dialog.ShowDialog() == DialogResult.OK) + { + filePath = dialog.FileName; + } + } + + return filePath; + } + } +} |