1

Topic: Problem with a dialog box call

In my program in file MyDialog1.cpp I wrote: CSolutionDialog solutionDialog (this); solutionDialog (iterations,sigma0,calcedx,calcedy,calcedz,calcedVx,calcedVy,calcedVz,calceddeltax,calceddeltay,calceddeltaz,calceddeltaVx,calceddeltaVy,calceddeltaVz); solutionDialog. DoModal (); In a debugger at me jumps out a file wincore.cpp and in it function DefWindowProc: LRESULT CWnd:: DefWindowProc (UINT nMsg, WPARAm wParam, LPARAM lParam) {if (m_pfnSuper! =NULL) return:: CallWindowProc (m_pfnSuper, m_hWnd, wParam, lParam); WNDPROC pfnWndProc; if ((pfnWndProc =*GetSuperWndProcAddr ()) == NULL) return:: DefWindowProc (m_hWnd, nMsg, wParam, lParam); else return:: CallWindowProc (pfnWndProc, m_hWnd, nMsg, wParam, lParam);} The stop in a file wincore.cpp as DefWindowProc happens at line return:: CallWindowProc (m_pfnSuper, m_hWnd, wParam, lParam); Thus jumps out a window with the message: the Raw exception to 0x3030302E address in myprogram.exe: 0xC0000005: Access violation (parameters: 0x00000008) At attempt to push button "Continue" in this window happens nothing (that once that some times) - it is necessary to push button "Interrupt". But the most interesting - when I in a debugger do break points in functions, all normally works for me. Also all normally works for me, if I delete a line solutionDialog (iterations,sigma0,calcedx,calcedy,calcedz,calcedVx,calcedVy,calcedVz,calceddeltax,calceddeltay,calceddeltaz,calceddeltaVx,calceddeltaVy,calceddeltaVz); that is if there are two lines: CSolutionDialog solutionDialog (this); solutionDialog. DoModal (); In what the reason of it? How to me to rectify this error - that I always had a dialogue solutionDialog?

2

Re: Problem with a dialog box call

Hello, RussianFellow, you wrote: RF>... All normally works, if I delete a line RF> RF> solutionDialog (iterations,sigma0,calcedx,calcedy,calcedz,calcedVx,calcedVy,calcedVz,calceddeltax,calceddeltay,calceddeltaz,calceddeltaVx,calceddeltaVy,calceddeltaVz); RF> RF> In what the reason of it? It is poorly parameters?

3

Re: Problem with a dialog box call

Hello, RussianFellow, you wrote: There is a small chance that the call stack helps to understand a problem. And so, something you there in the overloaded operator () bungled, and what exactly anybody except you cannot know

4

Re: Problem with a dialog box call

Hello, RussianFellow, you wrote: RF> But the most interesting - when I in a debugger do break points in functions, all normally works for me. Also all normally works for me, if I delete a line RF> In what the reason of it? How to me to rectify this error - that I always had a dialogue solutionDialog? Well you clarified the reason, a problem in a call of the operator () with one million parameters Look where  inside, or the code here spread.

5

Re: Problem with a dialog box call

All thanks, but the problem was solved by me - in the parameter list I transferred wrong values (something of type +61 of th order). When with these values I understood, dialogue began to be caused normally.