Wrox Programmer Forums
Go Back   Wrox Programmer Forums > C# and C > C++ and Visual C++ > Visual C++
|
Visual C++ Questions specific to Microsoft's Visual C++. For questions not specific to this Microsoft version, use the C++ Programming forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Visual C++ section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 30th, 2003, 10:43 AM
Registered User
 
Join Date: Dec 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Help in Assertion failure

Dear
I am working with the visual C++ version 6 for some programming in which it can handle input and output data storage and data displaying system. for all purpose I am using around 4 dialog boxes.

I am using the Microsoft FlexGrid Control(CMS FlexGrid) for display data on the screen, But when I tried to load the data to the dialog box containing the CMS FlexGrid by calling in a different dialog box, it is saying that there is an assertion failure, Would you please help me How I can manage to move on? I need your help.


some of the datas in brief is
1. From the debug file the following pop up is shown:

void AFX_CDECL CWnd::InvokeHelper(DISPID dwDispID, WORD wFlags, VARTYPE vtRet, void* pvRet, const BYTE* pbParamInfo, ...)
{
ASSERT(m_pCtrlSite != NULL); // not an OLE control (not yet, at least)
    if (m_pCtrlSite == NULL)
        return;
    va_list argList;
    va_start(argList, pbParamInfo);
    m_pCtrlSite->InvokeHelperV(dwDispID, wFlags, vtRet, pvRet, pbParamInfo,
        argList);
    va_end(argList);
}

2. Part of the the program for data loading was done as follows

for(Count=m_dOutPut.m_ctlFGrid.GetFixedRows();
    Count<m_dOutPut.m_ctlFGrid.GetRow();Count++)
    {
m_dOutPut.m_ctlFGrid.SetTextArray(GenID(Count,0),R andomVariable(0));
m_dOutPut.m_ctlFGrid.SetTextArray(GenID(Count,1),R andomVariable(1));
m_dOutPut.m_ctlFGrid.SetTextArray(GenID(Count,2),R andomVariable(2));
lsAmount.Format("%5d.00",rand());
m_dOutPut.m_ctlFGrid.SetTextArray(GenID(Count,3),l sAmount);
     }

int CDay5Dlg::GenID(int m_iRow, int m_iCol )
{
    int iNCols=m_dOutPut.m_ctlFGrid.GetCols();
    return(m_iCol+iNCols*m_iRow);

}

CString CDay5Dlg::RandomVariable(int m_iColumn)
{
CString StrLearn; // The return string
switch (m_iColumn)
{
case 0:
     StrLearn=" " ;
     break;
case 1:
        StrLearn=" ";
        break;
case 2;
        StrLearn=" ";
        break;
    default:
        StrLearn=" ";
         break;
}
return StrLearn;
}




Abdelkader Kedir
TU wien
[email protected]





Similar Threads
Thread Thread Starter Forum Replies Last Post
Programmer's assertion in getNextStepPos dishant XSLT 1 April 11th, 2008 09:48 AM
what is an assertion? coreyalbrightsr Java Basics 3 October 2nd, 2007 06:54 PM
Debug assertion failure for wincore aparnakamath2000 Visual C++ 0 August 28th, 2007 05:49 AM
Debug assertion about m_pCtrlSite attaboyu Visual C++ 10 November 14th, 2005 01:53 PM
"Debug Assertion Failure" elleetan Visual C++ 3 September 20th, 2005 06:25 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.