================================== Declaration ==================================
This article is original, reproduced in the text of the influential annotated author and source, and to ensure the integrity of the article.
Do not modify (including this statement) without the consent of the author, and reserve the right of legal investigation.
Do not use academic references without the consent of the author.
Do not use for commercial publication, commercial printing or commercial reference without the consent of the author.
In order to ensure the correct contents, we suggest that we should read the original text.
This article link: http://www.cnblogs.com/wlsandwho/p/4398314.html
=======================================================================
Or is it supposed to be based on his own magic series http://www.cnblogs.com/wlsandwho/p/4288818.html
=======================================================================
For multiple views, you can get multiple sets of toolbars to correspond to, Microsoft's many things are so, such as SQL Server Management Studio (2008)
But it's so much trouble for me.
Let me steal some slack and use a button.
1 voidcmainframe::onxxx ()2 {3 //TODO: Add Command handler code here4cview* pcurview= ((cmainframe*) (AfxGetApp ()->m_pmainwnd))->mdigetactive ()GetActiveView ();//<------------------- this line5 6 if(pcurview==gpFV1)7 {8MessageBox (TEXT ("1"));9 }Ten Else One { AMessageBox (TEXT ("2")); - } -}
As for the brackets, it's a personal hobby.
MFC MDI Gets the current view