Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>See the <a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.openfiledialog.multiselect.aspx" rel="nofollow noreferrer">OpenFileDialog::Multiselect</a> property, from the docs: </p> <blockquote> <p>Gets or sets a value indicating whether the dialog box allows multiple files to be selected.</p> </blockquote> <p>To get the list of files selected you should use the <a href="http://msdn.microsoft.com/en-us/library/system.windows.forms.filedialog.filenames.aspx" rel="nofollow noreferrer">OpenFileDialog::FileNames</a> property.</p> <p>Adding style <strong>OFN_ALLOWMULTISELECT</strong>, see this Article <a href="http://www.codeguru.com/cpp/w-d/doc_view/misc/article.php/c6119/" rel="nofollow noreferrer">Multiple File Selection Without Any Extra Code</a></p> <p>CodeProject Article: <a href="http://www.codeproject.com/Articles/28015/SelectDialog-A-Multiple-File-and-Folder-Select-Dia" rel="nofollow noreferrer">SelectDialog - A Multiple File and Folder Select Dialog</a></p> <p><strong>ADDED:</strong> See this added sample code for Multiple Files Selection in C#:</p> <pre><code>OpenFileDialog d = new OpenFileDialog(); d.Filter = "All files|*.*"; d.Multiselect = true; if (d.ShowDialog() == System.Windows.Forms.DialogResult.OK) { foreach (string fileName in d.FileNames) { // ... do something ... } } </code></pre> <p><strong>For Multiple Folder selection</strong>, </p> <p>You can use TreeView control by populating it with the Directory structure using the below reference:</p> <p><a href="https://stackoverflow.com/questions/6239544/c-sharp-how-to-populate-treeview-with-file-system-directory-structure">Populate TreeView with file system directory structure</a></p> <p>Secondly, you can allow multiple selection using SelectedNodes of TreeView Control to select multiple folders.</p> <p><a href="http://www.codeproject.com/Articles/2756/C-TreeView-with-multiple-selection" rel="nofollow noreferrer">C# TreeView with multiple selection</a></p> <p><strong><a href="http://www.ssware.com/articles/folderbrowserdialog-unmasked-everything-you-wanted-to-know-about-the-folder-browser-component-from-dotnet-framework.htm" rel="nofollow noreferrer">FolderBrowserDialog Control</a></strong></p> <p>Hope this will help you!</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload