Discussion:
Assertion in afxwin1 line 24
(too old to reply)
g***@gmail.com
2007-12-28 04:31:47 UTC
Permalink
Hi Folks,

I am getting this strange assertion(Assertion in afxwin1 line 24) in
my code after the following code statement.

Where Command_Formate is my class derived from Cproperty page.

Command_Formate::Command_Formate()
: CPropertyPage(Command_Formate::IDD,IDS_NA_TESTTOOL)

One thing I noticed is when I run my code with the option (use mfc in
a shared dll) I don't see these assertions displayed but when I run
these with the option(use mfc in a static library ) I get to see the
assertions .

Do I have to set some option to hide the assertions or is there
anything wrong with the code ?

Regards,
JLD
RainMan
2008-03-02 13:57:00 UTC
Permalink
Something wrong with a code.

I am not able to tell you exactly what is going on, since I could not fin
afxwin1 file on my machile with VS6, VS 2005 and VS 2008 installed.
What tool are you using to write/build your code?

Assertions works only for debug builds and show you what actually went wrong.
Each assertion evaluates expression that should tell you what caused it.
Usually it has some comments explaining what can cause it.

The most frequent mistake MFC programmers do, is to call functions that
require valid windows handle attached to MFC object:
ASSERT(::IsWindow(m_hWNd));
Little more detailed description of your problem would be helpful in
determining what is leading to your problem.
--
RainMan
Post by g***@gmail.com
Hi Folks,
I am getting this strange assertion(Assertion in afxwin1 line 24) in
my code after the following code statement.
Where Command_Formate is my class derived from Cproperty page.
Command_Formate::Command_Formate()
: CPropertyPage(Command_Formate::IDD,IDS_NA_TESTTOOL)
One thing I noticed is when I run my code with the option (use mfc in
a shared dll) I don't see these assertions displayed but when I run
these with the option(use mfc in a static library ) I get to see the
assertions .
Do I have to set some option to hide the assertions or is there
anything wrong with the code ?
Regards,
JLD
Loading...