<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : CFileDialog using MFC on Vista</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : General Discussion : CFileDialog using MFC on Vista]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Sat, 18 Apr 2026 06:49:29 +0000</pubDate>
  <lastBuildDate>Tue, 02 Dec 2008 16:52:01 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=10550</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : Wow I really appreciate thanks...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43372&amp;title=cfiledialog-using-mfc-on-vista#43372</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=686">cpede</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 02 December 2008 at 4:52pm<br /><br />Wow I really appreciate thanks <img src="https://forum.codejock.com/smileys/smiley32.gif" border="0"><DIV>&nbsp;</DIV><DIV>-cpede</DIV>]]>
   </description>
   <pubDate>Tue, 02 Dec 2008 16:52:01 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43372&amp;title=cfiledialog-using-mfc-on-vista#43372</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : It is a while since I did this,...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43371&amp;title=cfiledialog-using-mfc-on-vista#43371</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2426">robin_l</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 02 December 2008 at 3:28pm<br /><br /><P>It is a while since I did this, but what I do is the following. In a class derived from CFileDialog, I include the following in the declaration:</P><P><BR>protected:<BR>DECLARE_INTERFACE_MAP()<BR>BEGIN_INTERFACE_PART(FileDialogControlEvents, IFileDialogControlEvents)<BR>&nbsp; STDMETHOD(OnItemSelected)(IFileDialogCustomize *, DWORD, DWORD);<BR>&nbsp; STDMETHOD(OnButtonClicked)(IFileDialogCustomize *, DWORD);<BR>&nbsp; STDMETHOD(OnCheckButtonToggled)(IFileDialogCustomize *, DWORD, BOOL);<BR>&nbsp; STDMETHOD(OnControlActivating)(IFileDialogCustomize *, DWORD);<BR>END_INTERFACE_PART_OPTIONAL(FileDialogControlEvents)</P><P><BR>Then in the source file, something like:</P><P>BEGIN_INTERFACE_MAP(CMyDialog, CFileDialog)<BR>&nbsp; INTERFACE_PART(CMyDialog, ID_IFileDialogControlEvents_MFC, FileDialogControlEvents)<BR>END_INTERFACE_MAP()</P><P>in the constructor you need to include</P><P>USE_INTERFACE_PART_STD(FileDialogControlEvents);</P><P><BR>you then need to implement the methods (the ones below are blank)</P><P>STDMETHODIMP CMyDialog::XFileDialogControlEvents::OnItemSelected( IFileDialogCustomize *pfdc, DWORD dwIDCtl, DWORD dwIDItem )<BR>{<BR>&nbsp;METHOD_PROLOGUE(CMyDialog, FileDialogControlEvents)<BR>&nbsp;return S_OK;<BR>}</P><P><BR>STDMETHODIMP CMyDialog::XFileDialogControlEvents::OnButtonClicked( IFileDialogCustomize *pfdc, DWORD dwIDCtl )<BR>{<BR>&nbsp;METHOD_PROLOGUE(CMyDialog, FileDialogControlEvents)<BR>&nbsp;return S_OK;<BR>}</P><P>STDMETHODIMP CMyDialog::XFileDialogControlEvents::OnCheckButtonToggled( IFileDialogCustomize *pfdc, DWORD dwIDCtl, BOOL bChecked )<BR>{<BR>&nbsp;METHOD_PROLOGUE(CMyDialog, FileDialogControlEvents)<BR>&nbsp;return S_OK;<BR>}</P><P>STDMETHODIMP CMyDialog::XFileDialogControlEvents::OnControlActivating( IFileDialogCustomize *pfdc, DWORD dwIDCtl )<BR>{<BR>&nbsp;METHOD_PROLOGUE(CMyDialog, FileDialogControlEvents)<BR>&nbsp;return S_OK;<BR>}</P><P>STDMETHODIMP_(ULONG) CMyDialog::XFileDialogControlEvents::AddRef()<BR>{<BR>&nbsp;METHOD_PROLOGUE(CMyDialog, FileDialogControlEvents)<BR>&nbsp;return pThis-&gt;ExternalAddRef();<BR>}</P><P>STDMETHODIMP_(ULONG) CMyDialog::XFileDialogControlEvents::Release()<BR>{<BR>&nbsp;METHOD_PROLOGUE(CMyDialog, FileDialogControlEvents)<BR>&nbsp;return pThis-&gt;ExternalRelease();<BR>}</P><P>STDMETHODIMP CMyDialog::XFileDialogControlEvents::QueryInterface(<BR>&nbsp;REFIID iid, void FAR* FAR* ppvObj)<BR>{<BR>&nbsp;METHOD_PROLOGUE(CMyDialog, FileDialogControlEvents)<BR>&nbsp;ENSURE(ppvObj != NULL);<BR>&nbsp;return (HRESULT)pThis-&gt;ExternalQueryInterface(&amp;iid, ppvObj);<BR>}<BR></P>]]>
   </description>
   <pubDate>Tue, 02 Dec 2008 15:28:39 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43371&amp;title=cfiledialog-using-mfc-on-vista#43371</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : Thanks for the reply. I know...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43370&amp;title=cfiledialog-using-mfc-on-vista#43370</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=686">cpede</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 02 December 2008 at 2:43pm<br /><br />Thanks for the reply.<DIV>I know that this is the interface to look for, and what I should do is to implement this interface and Advise the IFileDialog with this event connection point.</DIV><DIV>&nbsp;</DIV><DIV>But when using CFileDialog in MFC 9 this already implements this interface, but by looking in the MFC code this implementation is empty.</DIV><DIV>&nbsp;</DIV><DIV>My question is really can I redirect this interface to my own implementation?</DIV><DIV>Or is it possible to do a simple virtual inheritance?</DIV><DIV>What happens if I advice with my own, where does it leave the MFC implementation?</DIV><DIV>&nbsp;</DIV><DIV>-cpede</DIV>]]>
   </description>
   <pubDate>Tue, 02 Dec 2008 14:43:22 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43370&amp;title=cfiledialog-using-mfc-on-vista#43370</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : Look at theIFileDialogControlEvents...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43367&amp;title=cfiledialog-using-mfc-on-vista#43367</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2426">robin_l</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 02 December 2008 at 11:35am<br /><br /><P>Look at the&nbsp;<FONT size=2>IFileDialogControlEvents interface for handling button clicks etc.</FONT></P><P>I'm not sure how you change from the default control size though....</P>]]>
   </description>
   <pubDate>Tue, 02 Dec 2008 11:35:07 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43367&amp;title=cfiledialog-using-mfc-on-vista#43367</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : Well I was actually looking for...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43362&amp;title=cfiledialog-using-mfc-on-vista#43362</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=686">cpede</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 02 December 2008 at 7:04am<br /><br />Well I was actually looking for a solution. Going back to old technology is not my style, I would rather solve the issues in front of me, - too early for me to resign.<DIV>&nbsp;</DIV><DIV>Am&nbsp;I the only one making a custom CFileDialog? Looking in MSDN did not solve anything, and they are also terrible in answering posts at there forum.</DIV><DIV>&nbsp;</DIV><DIV>-cpede</DIV>]]>
   </description>
   <pubDate>Tue, 02 Dec 2008 07:04:01 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43362&amp;title=cfiledialog-using-mfc-on-vista#43362</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : Set the last parameter in CFileDialogs...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43356&amp;title=cfiledialog-using-mfc-on-vista#43356</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=150">Sven</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 02 December 2008 at 5:40am<br /><br />Set the last parameter in CFileDialogs constructor to FALSE and you will get the XP implementation on Vista too.]]>
   </description>
   <pubDate>Tue, 02 Dec 2008 05:40:56 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43356&amp;title=cfiledialog-using-mfc-on-vista#43356</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : The new file dialog is one of...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43332&amp;title=cfiledialog-using-mfc-on-vista#43332</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2198">znakeeye</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 01 December 2008 at 11:30am<br /><br /><DIV>The new file dialog is one of the reasons why I switched back to XP <img src="http://forum.codejock.com/smileys/smiley17.gif" border="0"></DIV>]]>
   </description>
   <pubDate>Mon, 01 Dec 2008 11:30:06 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43332&amp;title=cfiledialog-using-mfc-on-vista#43332</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : I would really appreciate if someone...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43318&amp;title=cfiledialog-using-mfc-on-vista#43318</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=686">cpede</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 01 December 2008 at 8:17am<br /><br />I would really appreciate if someone knows answers to these problems <img src="http://forum.codejock.com/smileys/smiley19.gif" border="0"> <DIV>&nbsp;</DIV><DIV>The positioning is only cosmetic, but the control events are important. Browsing the web only reveals that I should make a class derived from <FONT size=2>IFileDialogControlEvents abd use the Advise method, but since VS2008 MFC CFileDialog already does that, there must be an easier way??</FONT></DIV><DIV><FONT size=2></FONT>&nbsp;</DIV><DIV><FONT size=2>-cpede</FONT></DIV>]]>
   </description>
   <pubDate>Mon, 01 Dec 2008 08:17:24 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=43318&amp;title=cfiledialog-using-mfc-on-vista#43318</guid>
  </item> 
  <item>
   <title><![CDATA[CFileDialog using MFC on Vista : When using VS2008 and MFC I automatically...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=34900&amp;title=cfiledialog-using-mfc-on-vista#34900</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=686">cpede</a><br /><strong>Subject:</strong> 10550<br /><strong>Posted:</strong> 08 May 2008 at 2:59am<br /><br />When using VS2008 and MFC I automatically get the Vista look on my file open dialogs. But when I have added a template this is not included :-(<DIV>&nbsp;</DIV><DIV>I can then retrieve the GetIFileDialogCustomize interface and add controls. And this also works for me. </DIV><UL><LI>How can I better control the placement of the controls? E.g. if I wan to add a large edit field called Comments, I cannot control the size of it?<BR>My other question is about the events.<BR></LI><LI>Is there an easy way to overwrite the control events in MFC CFileDialog? In the MFC implementation I can see the the events are implemented, but how do I get access or overwrites then. E.g. the OnButtonClicked?</LI></UL><P>Thanks, cpede</P>]]>
   </description>
   <pubDate>Thu, 08 May 2008 02:59:00 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10550&amp;PID=34900&amp;title=cfiledialog-using-mfc-on-vista#34900</guid>
  </item> 
 </channel>
</rss>