Solved

Release build crash pWndParent->m_pCtrlCont->AttachControlSite(this);

Posted on 2004-05-02
3
630 Views
Last Modified: 2013-11-20
Hi,

I have an application using RichEdit 2.0 controls in a SDI FormView. When linked against the release version of the MFC library it crashes
on the pWndParent->m_pCtrlCont->AttachControlSite(this); call in

void CWnd::AttachControlSite(CHandleMap* pMap)
{
      if (this != NULL && m_pCtrlSite == NULL)
      {
            // Determine if parent is an OLE control container
            CWnd* pWndParent = (CWnd*)pMap->LookupPermanent(::GetParent(m_hWnd));
            if (pWndParent != NULL && pWndParent->m_pCtrlCont != NULL)
            {
                  // delegate through helper in COleControlSite
                  pWndParent->m_pCtrlCont->AttachControlSite(this);
            }
      }
}

(WINOCC.CPP)

I compiled my program with debug information linked against the Release version of MFC and stepped into the crash and  it occurs after a PumpMessage call deep within MFC :-( I am rather puzzled about this problem and would appreciate any suggestions to resolve this.

I already checked my message handlers for correct format so I dont think it is caused by any of my costum registered window messages...

Confused greetings,
Thees.

0
Comment
Question by:Bender979
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 7

Accepted Solution

by:
vijay_visana earned 125 total points
ID: 10974827
There can be many reasons so following article give you very good insight in release problem
go thru it.

http://www.codeproject.com/debug/survivereleasever.asp
0
 

Author Comment

by:Bender979
ID: 10975401
Thanks, but I ran through the issues mentioned there already before posting here.
My message handlers have the correct format, it also happens with compiler optimizations turned off etc. pp.

:-(
0
 

Author Comment

by:Bender979
ID: 10978309
shame and even bigger shame on me, lol OK OK OK I overlooked a wrong message handler *hide in corner*

happens if you sit too long in front of your computer, lol. Cheers.
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
How to know only "File created" with EventLog 3 35
while loop over for loop 7 119
viewing source code from eclipse 13 111
sum13 challenge 24 150
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
In this post we will learn different types of Android Layout and some basics of an Android App.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question