Solved

Getting a PATH from a user

Posted on 1998-07-13
5
131 Views
Last Modified: 2010-05-03
I am using the CommonDialog control to get files from the user. This is really easy. But how do I get just a PATH from the user? I tried the CommonDialog and it works as long as there is a file in the directory for the user to select. But some times the directory being selected is totaly empty and there is no way to use the ShowOpen dialog without a file being selected.
0
Comment
Question by:schworak
  • 3
5 Comments
 
LVL 6

Expert Comment

by:clifABB
Comment Utility
I'm afraid you may have to create your own dialog box.  This is the only solution I've ever been able to come up with.

I submit this as a comment.  If, as I believe, there is no alternative other than creating your own dialog box, let me know and I'll resubmit as an answer.
0
 
LVL 2

Accepted Solution

by:
rayb earned 100 total points
Comment Utility
Check out this site:  http://www.mvps.org/ccrp/
They've got a cool FolderTreeview control.
0
 
LVL 3

Author Comment

by:schworak
Comment Utility
I can't get the treeview control to even load up in VB. I have a help request in on the news group. What I have done in the mean time is just use the OpenSave method on the normal dialog control with junk as the file name. I don't need a file name so what ever is entered gets ignored for now. Not perfect, but it works.
0
 
LVL 3

Author Comment

by:schworak
Comment Utility
Sorry for the delay in testing the TreeView answer. There have been problems getting it properly installed. I now have the suggested method for installing so I will be able to test it's function now.
0
 
LVL 3

Author Comment

by:schworak
Comment Utility
WOO HOO! That works great! Thanks for pointing me to the right place!
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now