Link to home
Start Free TrialLog in
Avatar of pibarale
pibaraleFlag for India

asked on

What is handle to the CFileDialog Dropdown control created when we type in the FileName control?

How do we find the handle of the dropdown control created when we type something in the filename control area. Please refer to the image and the dropdown control is highlighted in the red rectangle.
Untitled.png
SOLUTION
Avatar of Subrat (C++ windows/Linux)
Subrat (C++ windows/Linux)
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of pibarale

ASKER

Hi Subrat2009
Thanks for the prompt respnose.
But all methods you suggest need those say handles (parent and child) and classes name and all these what I am looking for and raise these query.

How should I start?
Could you give me some hint and I am not looking for all the bunch of code?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hi Dan,
It is nice to see you again in this discussion.
Actually I am trying to play with messages like WM_KEYUP when the user select some items in this dropdown box say "Program Files". When the user select "Program Files" by pressing VK_DOWN and then release, the text  "Program Files" will be in the combox. This is what I want to stop. I have already implemented some hooks. If know the handle of this dynamic dropdown box then probably it is done.
I will be come back soon after reading all your suggestions.
Thanks
Pibarale.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hi mrwad99,
Thanks for contributions. But this does not resolve this problem.
DanRollins/mrwad99,
Once again I consolidate my problem. Please find the following.
As shown In the screen shot above, when I type a character say 'p' a list of items starting with this character is populated in the dropdown box shown in the red rectangle. Then I select an item from the dropdown box either with left mouse (WM_LBUTTONDOWN) or  down arrow key (VK_DOWN),; this selected item is displayed in the combox box.
My objective is to handle this two messages.
ha... ha... Yes, Dan....
I want to diable the OK button if the item selected using the above procedure has some specific name. That's it.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Dan,
OnFileNameChange is captured if select an item in the list box i.e, CDN_SELCHANGE is captured in the CFileDialog Hook initialize in the constructor.

m_ofn.lpfnHook = reinterpret_cast< LPOFNHOOKPROC >( FileDialogHookProc );
But the same is not happen in case of this smarty dropsown box. So I stuck here.
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
It was a nice discussion.
pibarale

Thank you for taking the time to accept answers.  However, it is clear that you are not fully aware of how to *grade* answers.

We have provided you with working code that does *exactly* what you requested.  Not partially, but *exactly* what you want.  For that, we expect an A.  

Please read https://www.experts-exchange.com/help.jsp#hs=29&hi=403.  To quote, "an answer is worth an A, unless it doesn't resolve your issue."  I am now thinking that you did not receive a fully working solution, for which we can surely help you further.  Is this the case?  Can you take a few more minutes and explain why you decided on a B as opposed to an A?