Solved

Debug Assertion Failed.

Posted on 1997-09-06
5
583 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

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

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

If you have ever found yourself doing a repetitive action with the mouse and keyboard, and if you have even a little programming experience, there is a good chance that you can use a text editor to whip together a sort of macro to automate the proce…
In this article, I will show how to use the Ribbon IDs Tool Window to assign the built-in Office icons to a ribbon button.  This tool will help us to find the OfficeImageId that corresponds to our desired built-in Office icon. The tool is part of…
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…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…

831 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