<?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 : Problem with CXTPTabClientWnd and background image</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Toolkit Pro : Problem with CXTPTabClientWnd and background image]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Sun, 14 Jun 2026 12:14:45 +0000</pubDate>
  <lastBuildDate>Wed, 10 Jan 2007 15:15:37 +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=5854</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[Problem with CXTPTabClientWnd and background image : Hi again,Sorry, the first step...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=5854&amp;PID=19143&amp;title=problem-with-cxtptabclientwnd-and-background-image#19143</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2606">Cheerios</a><br /><strong>Subject:</strong> 5854<br /><strong>Posted:</strong> 10 January 2007 at 3:15pm<br /><br />Hi again,<br><br>Sorry, the first step would be to replace all instances of "CWnd" with "CXTPTabClientWnd" in <i>MDIClient.h </i>and <i>MDIClient.cpp</i>.<br><br><br>]]>
   </description>
   <pubDate>Wed, 10 Jan 2007 15:15:37 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=5854&amp;PID=19143&amp;title=problem-with-cxtptabclientwnd-and-background-image#19143</guid>
  </item> 
  <item>
   <title><![CDATA[Problem with CXTPTabClientWnd and background image : Hi,I actually discovered my own...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=5854&amp;PID=19142&amp;title=problem-with-cxtptabclientwnd-and-background-image#19142</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2606">Cheerios</a><br /><strong>Subject:</strong> 5854<br /><strong>Posted:</strong> 10 January 2007 at 3:05pm<br /><br /><span ="copy">Hi,<br><br>I actually discovered my own workaround.<br><br>I found some code written by Bogdan Ledwig that uses a generalized custom MDI Client class for changing the parent MDI background image (<a href="http://www.codeguru.com/cpp/w-d/doc_view/background/article.php/c3311/" target="_blank">http://www.codeguru.com/cpp/w-d/doc_view/background/article.php/c3311/</a>).&nbsp; I merely changed the MDIClient class's inheritance to CXTPTabClientWnd versus CWnd (i.e., replaced all instances of "CWnd" with "</span><span ="copy">CXTPTabClientWnd").&nbsp; <br><br>Steps (hopefully, all):<br></span><br><span ="copy">- First, replace all instances of "CWnd" with "CXTPTabClientWnd" in MainFrm.h and MainFrm.cpp files.</span><br><span ="copy"><br>- In my MainFrm.h file, I made the following changes:<br>1) Added #include "MDIClient.h"<br>2) Changed my client window definition from "CXTPTabClientWnd m_wndClient" to "CMDIClient m_wndClient" <br>3) Added function definition public: CMDIClient&amp; GetMDIClient();<br>4) After class definition, added the following inline function:<br>&nbsp;&nbsp;&nbsp; inline<br>&nbsp;&nbsp;&nbsp; CMDIClient&amp; CMainFrame::GetMDIClient()<br>&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; return m_wndClient;<br>&nbsp;&nbsp;&nbsp; }<br><br>- In my MainFrm.cpp I made the following changes:<br>1) In the MainFrm::OnCreate method near the very end (right before the call to RedrawWindow), I inserted the following:<br><br>&nbsp;&nbsp;&nbsp; GetMDIClient().SetBitmap(IDB_BACKGROUND);<br>&nbsp;&nbsp;&nbsp; GetMDIClient().SetDisplayMode(CMDIClient::DisplayModesEnum( 2 ));<br><br>I hope this helps someone in the future.&nbsp; Good luck!<br><br></span>]]>
   </description>
   <pubDate>Wed, 10 Jan 2007 15:05:31 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=5854&amp;PID=19142&amp;title=problem-with-cxtptabclientwnd-and-background-image#19142</guid>
  </item> 
  <item>
   <title><![CDATA[Problem with CXTPTabClientWnd and background image : Hi, I am a newbie to MFC and apologize...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=5854&amp;PID=18424&amp;title=problem-with-cxtptabclientwnd-and-background-image#18424</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2606">Cheerios</a><br /><strong>Subject:</strong> 5854<br /><strong>Posted:</strong> 20 December 2006 at 3:24pm<br /><br /><br>Hi, <br><br>I am a newbie to MFC and apologize ahead of time for my ignorance.&nbsp; I am having problems creating a background image in a Ribbon MDI parent window that uses the CXTPTabClientWnd class.&nbsp; I have read two posts from this forum on this subject (one by Cedric Caron - "CXTPTabClientWnd and background image" and another by Simon HB9DRV - "CXTPTabClientWnd Question"), but I'm still not having any success.<br><br>Here's what I've tried doing so far:<br><br>(1) I've built a client window class based on the example given in <a href="http://www.codeguru.com/forum/archive/index.php/t-319786.html" target="_blank">http://www.codeguru.com/forum/archive/index.php/t-319786.html</a>.&nbsp; <br>(2) I then had&nbsp; the client window class inherit from the XTPTabClientWnd class.&nbsp; <br>(3) I then tried to override the OnFillBackground() method of CXTPClientWnd, but I wasn't sure what this OnFillBackground() override function should have in it.&nbsp; <br>(4) Then I added a new member variable of the type of the new client window class in my CMainFrame class to replace the existing CXTPClientWnd member variable.&nbsp; <br><br>Are these steps correct?&nbsp; Am I missing something?&nbsp; I keep getting an error when I try to subclass m_hWndMDIClient in CMainFrame::OnCreate like Cedric Caron mentioned in his post.<br><br>FYI, the structure of the code for my application is quite similar to that of the Ribbon MDI Sample.<br><br><br>Thanks in advance for your help!<br>&nbsp;<br><br><strong></strong>]]>
   </description>
   <pubDate>Wed, 20 Dec 2006 15:24:51 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=5854&amp;PID=18424&amp;title=problem-with-cxtptabclientwnd-and-background-image#18424</guid>
  </item> 
 </channel>
</rss>