Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3785856
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T11:35:34+00:00 2026-05-19T11:35:34+00:00

I have a VB/C# .NET 2.0 project that, if possible, I would like to

  • 0

I have a VB/C# .NET 2.0 project that, if possible, I would like to customize the OpenFileDialog box to select a directory rather than a file. The reason for this is because the FolderBrowserDialog is ugly and a pain for most of my users to navigate using.

I know how to filter extensions using OpenFileDialog, but is there a flag or variable I can set that will allow me to only show directories and select those directories that is built into .NET? And if not, what is a good third party dialog to use/where should I begin if I am to create my own?

I apologize, I do not have much experience creating frontends. Any help or direction on this would be greatly appreciated 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T11:35:35+00:00Added an answer on May 19, 2026 at 11:35 am

    After checking the question that Mayank posted, I found out that there is no native way to do this in .NET. However, one of the posts by Scott Wisniewski yielded the exactly what I was looking for.

    The only thing I had to do to make this work in .NET 2.0 was add the following code to my project in a file called ExtensionAttribute.cs. This method is not needed in .NET 3.5+, but please note that this is reported to not work at all with Visual Studio 2005.

    namespace System.Runtime.CompilerServices
    {
       [AttributeUsage(AttributeTargets.Method)]
       public sealed class ExtensionAttribute : Attribute
       {
          public ExtensionAttribute() { }
       }
    }
    

    Again, this code snippet only works with Visual Studio 2008, it will not work with VS 2005.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a vb script that modify file in user folder i would like
I have a class library that targets .NET 3.5. Now, I would like to
I have a .NET project that I've been compiling with Visual Studio and running
I have a vb.net project that loads plugin dlls at runtime to crunch some
I have an ASP.NET project that contains many classes. I am thinking about creating
I have accumulated an ASP.NET project that was running everything off of one page
We have an ASP.Net MVC project that will start with a single web server
I have an Asp.net MVC project that modestly uses jQuery scripts. My views also
I have an ASP.NET VB.NET web project that references a VB.NET class library. I
Background : I have a asp.net webapplication project that should contain a public and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.