?
Solved

Directory Selection Dialog Box

Posted on 1997-09-09
1
Medium Priority
?
211 Views
Last Modified: 2013-12-03

I am trying to find some information on the directories
list box found under the directories tab of the Tools Options dialog box in Visual C++ 4.2.  Double clicking on a blank line int the box brings up a button on the right hand side of the line with three dots.  Pushing this button brings up a dialog similar to file open but only shows directories which can be chosen.  I would assume the list box stuff is done through sub-classing but any info would be appreciated.  Finally is this directory open dialog box something I can use such as the File Open or Color Selection dialog or is it designed specifically by Microsoft for this product???
         Thanks in advance,
                   Derek
0
Comment
Question by:derekl
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 2

Accepted Solution

by:
tarang earned 100 total points
ID: 1406274
I doubt very much that the list box is sub-classed.  It would be
much easier to use DlgDirList function to populate the list box.
However a much better method exists.  Use GetOpenFileName and in
the OPENFILENAME structure give it an lpfnHook where you can
intercept the WM_INITDIALOG and WM_COMMAND messages.  You can
then hide and resize the dialog and then get whatever the user
does.  If messing around with the dialog at run-time is not
palitable to you then you can always load a copy commdlg.dll into
VC and look at it's resources.  You can then copy the File Open
dialog and modify it.  You can then pass the copied and modified
resource as the lpTemplateName in the OPENFILENAME structure.

All common dialogs: Find, Font, Color, Open, Save, have API calls
and can be modified in similar methods to those described above.
0

Featured Post

 [eBook] Windows Nano Server

Download this FREE eBook and learn all you need to get started with Windows Nano Server, including deployment options, remote management
and troubleshooting tips and tricks

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After several hours of googling I could not gather any information on this topic. There are several ways of controlling the USB port connected to any storage device. The best example of that is by changing the registry value of "HKEY_LOCAL_MACHINE\S…
For most people, the WrapPanel seems like a magic when they switch from WinForms to WPF. Most of us will think that the code that is used to write a control like that would be difficult. However, most of the work is done by the WPF engine, and the W…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…

770 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