EditCategory
Input
EditQuestion
I need the functionality of browseing to choose a certain folder in my WPF application. How do I do it?
EditAnswer
You can try the 'Microsoft.Win32.OpenFileDialog' class in WPF's PresentationFramework.dll assembly. This dialog lets users specify multiple files to open.
WPF does not provide wrappers to certain Windows common dialogs, namely 'FolderBrowser', 'ColorDialog' and 'FontDialog'. But even the wrappers it does provide are wrappers over older XP-style dialogs, not Vista style dialogs.
Another thing you can do is use the common dialogs from the .NET 2.0 Windows Forms assembly. Since .NET 3.0 itself uses the .NET 2.0 CLR, you probably aren't adding any dependencies on your app, so why not?
EditRelated Information
A sample called "Vista Bridge" in the Windows SDK can help you get true Vista-like dialogs within WPF it that's your goal.
EditKeywords
Browse for folder, color dialog, font dialog