What is WPF equivalent of the open folder dialog of WindowsForms? - DOTNET

This is a discussion on What is WPF equivalent of the open folder dialog of WindowsForms? - DOTNET ; Hi, I am trying to enter the WPF world and stumbled when I needed the functionality of browseing to choose a certain folder, a very common component in Windows.Forms applications. Is there a corresponding component for WPF development? I suppose ...

+ Reply to Thread
Results 1 to 4 of 4

What is WPF equivalent of the open folder dialog of WindowsForms?

  1. Default What is WPF equivalent of the open folder dialog of WindowsForms?

    Hi,

    I am trying to enter the WPF world and stumbled when I needed the
    functionality of browseing to choose a certain folder, a very common
    component in Windows.Forms applications.

    Is there a corresponding component for WPF development? I suppose I could
    just add the Windows.Forms assembly toi my project, but that would make my
    WPF application very platform specific wouldn't it?

    --
    Thanks in advance,

    Juan Dent, M.Sc.

  2. Default Re: What is WPF equivalent of the open folder dialog of WindowsForms?


    "Juan Dent" <juanjr@nospam.nospam> wrote in message
    news159C8C5-8C25-471F-90FE-85A32AE7D0D6@microsoft.com...
    > Hi,
    >
    > I am trying to enter the WPF world and stumbled when I needed the
    > functionality of browseing to choose a certain folder, a very common
    > component in Windows.Forms applications.
    >
    > Is there a corresponding component for WPF development? I suppose I could
    > just add the Windows.Forms assembly toi my project, but that would make
    > my
    > WPF application very platform specific wouldn't it?
    >
    > --
    > Thanks in advance,
    >
    > Juan Dent, M.Sc.


    Don't you think WPF is already kind of platform-specific? Where do you
    think you are going to run WPF applications that WIndowsForms won't run?

    According to Nathan's book: "Both WindowsForms and WPF define managed
    classes that wrap Windows common dialogs, except ColorDialog, FontDialog,
    and FolderBrowser, which only occur in Windows. The easiest way to use
    these omitted dialogs is to use the ones from Windows Forms."

    Good luck.
    Robin S.



  3. Default RE: What is WPF equivalent of the open folder dialog of WindowsForms?

    Hi Juan,

    Yes, based on my knowledge, there is no build-in class support in current
    version of WPF. I would recommend you to use the one from .Net2.0 Winforms
    Forms assembly.

    Actually, there is no problem of using .Net2.0 assemblies in WPF. .Net3.0
    does not have its own CLR, it still leverages .Net2.0 CLR, and other
    ..Net2.0 core library assemblies. So it can be seen as a new service built
    on the .Net2.0. My original reply below contains more information:
    http://groups.google.com/group/micro.../msg/107c5888d
    cbb2441

    Since the .Net3.0 WPF must be built upon .Net2.0 CLR and FCL, whatever
    machine with .Net3.0 installed must have .Net2.0 either. So using .Net2.0
    Winforms Forms assembly in WPF has no platform requirment/dependency on the
    target machine.

    Hope this helps.

    Best regards,
    Jeffrey Tan
    Microsoft Online Community Support
    ==================================================
    Get notification to my posts through email? Please refer to
    http://msdn.microsoft.com/subscripti...ult.aspx#notif
    ications.

    Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
    where an initial response from the community or a Microsoft Support
    Engineer within 1 business day is acceptable. Please note that each follow
    up response may take approximately 2 business days as the support
    professional working with you may need further investigation to reach the
    most efficient resolution. The offering is not appropriate for situations
    that require urgent, real-time or phone-based interactions or complex
    project ****ysis and dump ****ysis issues. Issues of this nature are best
    handled working with a dedicated Microsoft Support Engineer by contacting
    Microsoft Customer Support Services (CSS) at
    http://msdn.microsoft.com/subscripti...t/default.aspx.
    ==================================================
    This posting is provided "AS IS" with no warranties, and confers no rights.


  4. Default RE: What is WPF equivalent of the open folder dialog of WindowsForms?

    Hi Juan ,

    Oh, further research shows that WPF PresentationFramework.dll assembly
    introduces Microsoft.Win32.OpenFileDialog class to allow a user to specify
    a filename for one or more files to open. You may use it directly in WPF.

    Additionally, you should be aware that the WPF APIs only wrap the XP-style
    dialogs, even on Windows Vista. The "Vista Bridge", provided in the Windows
    SDK, includes a reference sample of how to get Vista-style dialogs from WPF.

    Hope this helps.

    Best regards,
    Jeffrey Tan
    Microsoft Online Community Support
    ==================================================
    Get notification to my posts through email? Please refer to
    http://msdn.microsoft.com/subscripti...ult.aspx#notif
    ications.

    Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
    where an initial response from the community or a Microsoft Support
    Engineer within 1 business day is acceptable. Please note that each follow
    up response may take approximately 2 business days as the support
    professional working with you may need further investigation to reach the
    most efficient resolution. The offering is not appropriate for situations
    that require urgent, real-time or phone-based interactions or complex
    project ****ysis and dump ****ysis issues. Issues of this nature are best
    handled working with a dedicated Microsoft Support Engineer by contacting
    Microsoft Customer Support Services (CSS) at
    http://msdn.microsoft.com/subscripti...t/default.aspx.
    ==================================================
    This posting is provided "AS IS" with no warranties, and confers no rights.


+ Reply to Thread

Similar Threads

  1. Replies: 2
    Last Post: 12-06-2007, 06:26 PM
  2. Re: LV 8.5 browse dialog locks folder
    By Application Development in forum labview
    Replies: 1
    Last Post: 10-24-2007, 05:40 AM
  3. Double-click a folder browser dialog?
    By Application Development in forum CSharp
    Replies: 5
    Last Post: 10-05-2007, 11:41 PM
  4. C# code needed to open the windows "Open with" dialog
    By Application Development in forum DOTNET
    Replies: 1
    Last Post: 03-22-2006, 07:17 AM
  5. Replies: 5
    Last Post: 10-06-2003, 01:08 PM