<?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 : Memory leak in modeless CXTPPropertySheet?</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Controls : Memory leak in modeless CXTPPropertySheet?]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 13 May 2026 08:33:49 +0000</pubDate>
  <lastBuildDate>Tue, 14 Dec 2010 04:05:52 +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=17059</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[Memory leak in modeless CXTPPropertySheet? : Could it be that you need to do...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=61796&amp;title=memory-leak-in-modeless-cxtppropertysheet#61796</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=686">cpede</a><br /><strong>Subject:</strong> 17059<br /><strong>Posted:</strong> 14 December 2010 at 4:05am<br /><br />Could it be that you need to do this, using the good old way by calling <FONT color=#0000ff>delete this </FONT>in WM_NCDESTROY ?<DIV>&nbsp;</DIV><DIV>-cpede</DIV>]]>
   </description>
   <pubDate>Tue, 14 Dec 2010 04:05:52 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=61796&amp;title=memory-leak-in-modeless-cxtppropertysheet#61796</guid>
  </item> 
  <item>
   <title><![CDATA[Memory leak in modeless CXTPPropertySheet? : I did.   I have this in dest...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=59709&amp;title=memory-leak-in-modeless-cxtppropertysheet#59709</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6238">nick_w</a><br /><strong>Subject:</strong> 17059<br /><strong>Posted:</strong> 09 August 2010 at 12:04pm<br /><br /><DIV>I did. </DIV><DIV>&nbsp;</DIV><DIV>I have this in destructor</DIV><DIV>&nbsp;</DIV><DIV><FONT size=2><P>CPropertySheetDlg::~CPropertySheetDlg()</P><P>{</P><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>if</FONT></FONT><FONT size=2> ( m_pModelLessSheet )</P><P>{</P><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>delete</FONT></FONT><FONT size=2> m_pModelLessSheet-&gt;pNavigator;</P><P>m_pModelLessSheet-&gt;DestroyWindow();</FONT><FONT color=#008000 size=2><FONT color=#008000 size=2></P></FONT></FONT><FONT size=2><P>m_pModelLessSheet = </FONT><FONT color=#800000 size=2><FONT color=#800000 size=2>NULL</FONT></FONT><FONT size=2>;</P><P>}</P><P>}</P><DIV>if I add&nbsp;&nbsp; <FONT color=#008000 size=2><FONT color=#008000 size=2><FONT size=2><FONT color=#000000><FONT color=#0000ff size=2><FONT color=#0000ff size=2>delete</FONT></FONT><FONT size=2> m_pModelLessSheet;</FONT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <DIV>after destroy window, it will crash. </DIV><DIV></FONT></FONT></FONT></FONT></FONT>&nbsp;</DIV></DIV><DIV><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by oleg" alt="Originally posted by oleg" style="vertical-align: text-bottom;" /> <strong>oleg wrote:</strong><br /><br />Hi, <BR><BR>You need manually delete pointer to ps. You can add member in your class and delete it in destructor.</td></tr></table> </DIV></DIV>]]>
   </description>
   <pubDate>Mon, 09 Aug 2010 12:04:58 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=59709&amp;title=memory-leak-in-modeless-cxtppropertysheet#59709</guid>
  </item> 
  <item>
   <title><![CDATA[Memory leak in modeless CXTPPropertySheet? : Hi,  You need manually delete...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=59625&amp;title=memory-leak-in-modeless-cxtppropertysheet#59625</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 17059<br /><strong>Posted:</strong> 05 August 2010 at 5:41am<br /><br />Hi,<br /><br />You need manually delete pointer to ps. You can add member in your class and delete it in destructor.]]>
   </description>
   <pubDate>Thu, 05 Aug 2010 05:41:29 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=59625&amp;title=memory-leak-in-modeless-cxtppropertysheet#59625</guid>
  </item> 
  <item>
   <title><![CDATA[Memory leak in modeless CXTPPropertySheet? : I was testing modeless property...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=59598&amp;title=memory-leak-in-modeless-cxtppropertysheet#59598</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6238">nick_w</a><br /><strong>Subject:</strong> 17059<br /><strong>Posted:</strong> 03 August 2010 at 2:24pm<br /><br /><P style="MARGIN: 0in 0in 10pt" =Ms&#111;normal><FONT size=3 face=Calibri>I was testing modeless property sheet in </FONT><SPAN style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-no-proof: yes">CPropertySheetDlg::OnButtonTree()</SPAN><FONT size=3 face=Calibri> of PropertySheetDlg sample project. After I close the main window, I noticed there was memory leak for not deleting a </FONT><SPAN style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-no-proof: yes">CSamplePropertySheet </SPAN><FONT size=3 face=Calibri>object. So I called </FONT><SPAN style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-no-proof: yes">DestroyWindow()</SPAN><FONT size=3><FONT face=Calibri>at window close but the memory leak was still there. <?:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p></FONT></FONT></P><P style="MARGIN: 0in 0in 10pt" =Ms&#111;normal><FONT size=3><FONT face=Calibri>Any advice? Thanks. <o:p></o:p></FONT></FONT></P>]]>
   </description>
   <pubDate>Tue, 03 Aug 2010 14:24:50 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=17059&amp;PID=59598&amp;title=memory-leak-in-modeless-cxtppropertysheet#59598</guid>
  </item> 
 </channel>
</rss>