Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Directory Selection Dialog Box

Posted on 1997-09-09
1
Medium Priority
?
216 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

Learn Veeam advantages over legacy backup

Every day, more and more legacy backup customers switch to Veeam. Technologies designed for the client-server era cannot restore any IT service running in the hybrid cloud within seconds. Learn top Veeam advantages over legacy backup and get Veeam for the price of your renewal

Question has a verified solution.

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

This article shows how to make a Windows 7 gadget that extends its U/I with a flyout panel -- a window that pops out next to the gadget.  The example gadget shows several additional techniques:  How to automatically resize a gadget or flyout panel t…
If you have ever found yourself doing a repetitive action with the mouse and keyboard, and if you have even a little programming experience, there is a good chance that you can use a text editor to whip together a sort of macro to automate the proce…
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 response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

609 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