There are 2 API funcs GetOpenFileName\GetSaveFileName which produce identical dialog box. In this dialog users can select files/folders. Either of the two has toolbar in upper-right part of dialog box. This toolbar include 4 buttons:

Go to previous folder,Go to level-up folder,Create new folder and View select.

So I wonder how appearance of this toolbar can be controlled? Can I remove this toolbar from dialog box? Or can I replace picture on button's face with my own?

THX for reply in advance!
Posted on 2003-08-21 04:59:16 by Smarty
You can use a hook procedure for the SaveAs or Open dialogs and change the toolbar however you like. I think it is ID # 1088. Remember that that is the OFN_EXPLORER type dialog and the handle that is passed to the hook proc is not the parent of the toolbar but a sibling so in your WM_INITDIALOG you would do a GetParent to find the toolbars parent. At that point you can GetDlgItem to get the handle of the toolbar and add items, changes images or anything you want. If you use a hook proc you will loose the encasing window with the large buttons down the side. Of course you will have to find a way to get info from the toolbar as the WM_COMMAND messages are not sent to the hook, you must find them in the WM_NOTIFY handler.
Posted on 2003-08-21 05:10:25 by donkey
Thank for explanation, donkey! It's all work just as you write! And yes, ID of this toolbar is 440h = 1088d
Posted on 2003-08-22 11:07:45 by Smarty