在CFormView派生类中我定义了OnInitialUpdate和OnSize消息事件。
请问这俩个事件那个先执行。我在OnInitialUpdate和OnSize中都设定了断点,但是只看到了OnSize有执行。而 OnInitialUpdate没有执行到。但在我在OnInitialUpdate中只设了一个断点,可以看到OnInitialUpdate有执行。(OnSize不设断点).
我在OnSize中只设了一个断点,可以看到OnSize有执行。(OnInitialUpdate不设断点).
请问这是怎么回事。
另外那个Disassembly(分解)窗口是干吗用的。我调试程序他都要到分解窗口中去,看到只是汇编代码.不到分解窗口去不行吗?
谢谢各位了。

解决方案 »

  1.   

    CDocTemplate::InitialUpdateFrame() 
    Calling this function causes the views in that frame window to receive their OnInitialUpdate callsCView::OnInitialUpdate 
    virtual void OnInitialUpdate( );ResCalled by the framework after the view is first attached to the document, but before the view is initially displayed.
    CWnd::OnSize
    ResThe framework calls this member function after the window’s size has changed. 
      

  2.   

    写个日志文件就知道了,?这是什么意思。Disassembly(分解)窗口是干吗用的
      

  3.   

    在OnInitialUpdate写一句:
        MessageBox(NULL,"In OnInitialUpdate",NULL,MB_OK);
    在OnSize里写一句:
        MessageBox(NULL,"In OnSize",NULL,MB_OK);
    看哪个对话框先出现.