Is it possible to use the OpenFileDialog
class select a file OR folder? It appears only to allow the selection of a file, if you select a folder and then choose open it will navigate to that folder.
If the OpenFileDialog
can not be used for this is there another object I should be using?
EDIT: The scenario is that I have a tool that can upload one...many files or folders. I need to be able to provide a dialog like the OpenFileDialog
that allows a user to select a file, folder, or a combination of. I know about the FolderBrowseDialog
and that is not the answer in this case.
This is the solution I have been looking for, this article provides code and describes how to create a dialog that meets my needs.
CodeProject: Full Implementation of IShellBrowser
Yes, you can use OpenFileDialog to select a folder. Here is an article in CodeProject that demonstrated a way to do it (http://www.codeproject.com/KB/dialog/OpenFileOrFolderDialog.aspx).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With