MOre below...
On Jan 17, 10:14 am, Joseph M. Newcomer <newco...@flounder.com> wrote:
What are the control IDs of those IDC_ values? Could you have a conflict
with some other
ID?
If there is, it isn't obvious. The control receiving the unexplained
messages has IDC 3671. Here is the relevant part of resource.h:
#define IDC_TicksX 3671
#define IDC_DebugOutput07 3672
#define IDC_TicksY 3672
#define IDC_DebugOutput08 3673
#define IDC_NoneX 3673
#define IDC_DebugOutput09 3674
#define IDC_GridX 3674
#define IDC_DebugOutput10 3675
#define IDC_GridTypeX 3675
#define IDC_DebugOutput11 3676
#define IDC_RADIO4 3676
#define IDC_GridTypeX2 3677
#define IDC_GridTypeY 3677
The debug output IDCs are in a different dialog. I also searched all
files in the project for "3671" and its hex equivalent. But to be sure
it isn't due to an ID conflict, I have manually renumbered the IDs in
the affect dialog to a unique range and rebuilt everything. I still
get the same unwanted messages.
If they are sent via SendMessage, your stack backtrace should reveal who
sent them. Study it.
Here is the stack. The first entry is the message handler. message 273
(=0x111) is WM_COMMAND. 3679 is the IDC_TicksX (renumbered from the
above excerpt). The message is being sent during the modeless dialog
Create; that code is in CMainMenuToolbar. User has clicked within the
main menu (CWnd-derived), and that invokes the modeless Create. I
tried tracing through CreateDialogIndirect, but my MFC source code
apparently doesn't match, so I just get the disassembler.
Any assistance will be appreciated. I also tried to use the tool ATL/
MFC Tracer to see where the message was coming from, but this tool is
essentially undocumented.
CFitGridWindow::OnTicksX() Line 64
_AfxDispatchCmdMsg(CCmdTarget * pTarget=0x0830a290, unsigned int
nID=3679, int nCode=0, void (void)* pfn=0x00954089, void *
pExtra=0x00000000, unsigned int nSig=56, AFX_CMDHANDLERINFO *
pHandlerInfo=0x00000000) Line 82
CCmdTarget::OnCmdMsg(unsigned int nID=3679, int nCode=0, void *
pExtra=0x00000000, AFX_CMDHANDLERINFO * pHandlerInfo=0x00000000) Line
381 + 0x27 bytes
CDialog::OnCmdMsg(unsigned int nID=3679, int nCode=0, void *
pExtra=0x00000000, AFX_CMDHANDLERINFO * pHandlerInfo=0x00000000) Line
85 + 0x18 bytes
CWnd::OnCommand(unsigned int wParam=3679, long lParam=198698) Line
2300
CWnd::OnWndMsg(unsigned int message=273, unsigned int wParam=3679,
long lParam=198698, long * pResult=0x0038ed68) Line 1755 + 0x1e bytes
CWnd::WindowProc(unsigned int message=273, unsigned int wParam=3679,
long lParam=198698) Line 1741 + 0x20 bytes
AfxCallWndProc(CWnd * pWnd=0x0830a290, HWND__ * hWnd=0x00030826,
unsigned int nMsg=273, unsigned int wParam=3679, long lParam=198698)
Line 240 + 0x1c bytes
AfxWndProc(HWND__ * hWnd=0x00030826, unsigned int nMsg=273, unsigned
int wParam=3679, long lParam=198698) Line 389
7e418734
should ever appear.
I'd be reduced to single-stepping here. I'd set a breakpoint at the hook
recognizes the creation. Then I'd probably set a breakpoint at AfxWndProc
single-stepping (step-into, F11). Tedious as all-get-out, but I'm not
could begin to track down what is causing this.
does. I'd also be
behavior.
But you've definitely got something first-order-weird happening here. I
outlined.
Joseph M. Newcomer [MVP]