Click here to Skip to main content
15,915,508 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralReleaseMutex Pin
slah9-Aug-02 1:57
slah9-Aug-02 1:57 
GeneralRe: ReleaseMutex Pin
Simon.W9-Aug-02 2:22
Simon.W9-Aug-02 2:22 
GeneralRe: ReleaseMutex Pin
Tim Smith9-Aug-02 2:23
Tim Smith9-Aug-02 2:23 
GeneralVersions of applications (VS_VERSION_INFO) Pin
klm9-Aug-02 1:35
klm9-Aug-02 1:35 
GeneralRe: Versions of applications (VS_VERSION_INFO) Pin
Tim Smith9-Aug-02 2:26
Tim Smith9-Aug-02 2:26 
GeneralRe: Versions of applications (VS_VERSION_INFO) Pin
klm9-Aug-02 2:30
klm9-Aug-02 2:30 
GeneralRe: Versions of applications (VS_VERSION_INFO) Pin
Simon.W9-Aug-02 2:26
Simon.W9-Aug-02 2:26 
Questionhow to delete an object Pin
Jon Hulatt9-Aug-02 1:15
Jon Hulatt9-Aug-02 1:15 
Hi,

I'm dynamically creating an object like this:

CRuntimeClass * p_Rt;
p_Rt = RUNTIME_CLASS(CMyClass);
m_pMyClass = (CMyClass *) p_Rt->CreateObject();


which works fine. But how can i delete this object (the m_pMyClass) ?

if i try to delete it, i get a compiler error because the destructor in CMyClass is protected (becuase thats what classwizard set it to be; part of the whole DYNCREATE thing).

if i don't delete it, i get a memory leak. I must be missing something i think.

thakns jon

STL is a religeon. Enquiries to Reverend Christian Graus
AnswerRe: how to delete an object Pin
Tomasz Sowinski9-Aug-02 1:34
Tomasz Sowinski9-Aug-02 1:34 
GeneralRe: how to delete an object Pin
Jon Hulatt9-Aug-02 2:56
Jon Hulatt9-Aug-02 2:56 
AnswerRe: how to delete an object Pin
Mike Upton9-Aug-02 1:35
Mike Upton9-Aug-02 1:35 
GeneralGetting the menu of the CMDIChildWnd Pin
Poul Haahr Klemmensen9-Aug-02 0:43
Poul Haahr Klemmensen9-Aug-02 0:43 
GeneralRe: Getting the menu of the CMDIChildWnd Pin
Tomasz Sowinski9-Aug-02 0:59
Tomasz Sowinski9-Aug-02 0:59 
GeneralRe: Getting the menu of the CMDIChildWnd Pin
Steen Krogsgaard9-Aug-02 1:04
Steen Krogsgaard9-Aug-02 1:04 
GeneralRe: Getting the menu of the CMDIChildWnd Pin
Mike Upton9-Aug-02 1:27
Mike Upton9-Aug-02 1:27 
GeneralRe: Getting the menu of the CMDIChildWnd Pin
Poul Haahr Klemmensen9-Aug-02 3:46
Poul Haahr Klemmensen9-Aug-02 3:46 
GeneralRe: Getting the menu of the CMDIChildWnd Pin
Mike Upton9-Aug-02 3:56
Mike Upton9-Aug-02 3:56 
GeneralSimple question on Dialogboxes Pin
D Satya9-Aug-02 0:43
D Satya9-Aug-02 0:43 
GeneralRe: Simple question on Dialogboxes Pin
Steen Krogsgaard9-Aug-02 1:08
Steen Krogsgaard9-Aug-02 1:08 
GeneralRe: Simple question on Dialogboxes Pin
D Satya9-Aug-02 1:44
D Satya9-Aug-02 1:44 
GeneralRe: Simple question on Dialogboxes Pin
Steen Krogsgaard9-Aug-02 1:51
Steen Krogsgaard9-Aug-02 1:51 
GeneralRe: Simple question on Dialogboxes Pin
D Satya9-Aug-02 18:09
D Satya9-Aug-02 18:09 
GeneralCListBox takes up 100% CPU usage Pin
KHYEE9-Aug-02 0:31
KHYEE9-Aug-02 0:31 
GeneralRe: CListBox takes up 100% CPU usage Pin
Tomasz Sowinski9-Aug-02 1:02
Tomasz Sowinski9-Aug-02 1:02 
GeneralRe: CListBox takes up 100% CPU usage Pin
Anonymous11-Aug-02 22:29
Anonymous11-Aug-02 22:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.