Solved

Debug Assertion Failed.

Posted on 1997-09-06
5
584 Views
Last Modified: 2013-12-03
Just as my Visual C++ program begins to run, an error box appears with the title "Microsoft Visual C++ Debug Library". The box states "/Debug assertion failed.  Program: c:\mmha\mmha3.exe.  File: tooltip.cpp.  Line: 383.  For information on how your program can cause an assertion failure... (etc.) ...application."  I am stuck!
I should mention that the program was compiled for use with shared DLLs on my computer (and works fine on MY computer), but this problem occurs when I run the program on someone else's computer.  I previously had to copy several DLL files onto the other person's computer, but it is still not working of course!
0
Comment
Question by:Mark Ebden
5 Comments
 
LVL 2

Expert Comment

by:alexxx
ID: 1405993
Do you have the source to look it up (line 383)?
0
 

Author Comment

by:Mark Ebden
ID: 1405994
Tooltip.cpp is not something I wrote.

0
 
LVL 5

Accepted Solution

by:
dirtdart earned 50 total points
ID: 1405995
There are several problems that could have happened here.   First and most simple, when you copied the dll's to your other machine, did you properly register them?  If they are all properly registered, then it is probably a problem with accessing memory.  Your program has accessed a section of memory that has been marked as not usable by the client machine.  Along with this, you don't have the correct debug symbols for the dll in which the  error is occuring.  This is where teh debug assertation is failing.  The C computer is trying to find debug information that does not exist.  Once you get the debug symbols installed, you should be able to at least find where the error is occuring.
0
 
LVL 5

Expert Comment

by:y96andha
ID: 1405996
If you are running VC 5.0, this is the source code in question. You can choose to install source code for MFC when installing, and then you'll get the file referred to. Line 383 is marked with a =>.

            // add a "dead-area" tool for areas between toolbar buttons
            TOOLINFO ti; memset(&ti, 0, sizeof(TOOLINFO));
            ti.cbSize = sizeof(TOOLINFO);
            ti.uFlags = TTF_IDISHWND;
            ti.hwnd = m_hWnd;
            ti.uId = (UINT)m_hWnd;
            if (!pToolTip->SendMessage(TTM_GETTOOLINFO, 0, (LPARAM)&ti))
            {
                  ASSERT(ti.cbSize == sizeof(TOOLINFO));
                  ASSERT(ti.uFlags == TTF_IDISHWND);
                  ASSERT(ti.hwnd == m_hWnd);
                  ASSERT(ti.uId == (UINT)m_hWnd);
=> VERIFY(pToolTip->SendMessage(TTM_ADDTOOL, 0, (LPARAM)&ti));
            }

0
 

Author Comment

by:Mark Ebden
ID: 1405997
Thank you very much dirtdart!  I didn't register the DLLs.  But I don't have a clue how to register DLLs!  What should I do?

Thanks again.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

This article describes how to programmatically preset the "Pages per Sheet" option that's available with most printer drivers.   This setting lets you do "n-Up" printing, where two, four, or more pages are printed on each sheet of paper. If your …
After several hours of googling I could not gather any information on this topic. There are several ways of controlling the USB port connected to any storage device. The best example of that is by changing the registry value of "HKEY_LOCAL_MACHINE\S…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

856 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