I've managed to customize my own CFontDialog by adding a couple of buttons and a combo box. VS 2008 on XP Pro. My problem is that when I enabled the hookproc (yes I need to use a hookproc) in my DoModal override, OnInitDialog is no longer called. Why is that? Because of the WM_INITDIALOG message that gets handled in the hookproc? But then how can I get the code in OnInitDialog implemented? I tried simply copying the code from OnInitDialog to the WM_INITDIALOG handler in my hookproc but there were problems with finding the custom controls I had added. This is my first time trying to use a hookproc and good code examples are scarce. MS help that I've found doesn't seem to address this hookproc topic clearly enough for me.

Before enabling the hookproc, OnInitDialog worked just fine.