Date: 2009oct11
Platform: win32
Language: C/C++
Q. Why does my Visual C++ 6 program not compile in Visual C++ 7 ?
(Visual C++ 7 is part of Visual Studio 2005)
A. Some prototypes changed from VC6 to VC7...
(Visual C++ 7 is part of Visual Studio 2005)
ON_MESSAGE(WM_SOMEMESSAGE, OnSomeMessage)
vc6: didn't care
vc7: afx_msg LRESULT OnSomeMessage(WPARAM, LPARAM);
ON_BN_CLICKED(IDC_MYBUTTON, OnMyButtonClicked)
vc6: afx_msg LRESULT OnMyButtonClicked(WPARAM, LPARAM)
vc7: afx_msg void OnMyButtonClicked();
ON_LBN_DBLCLK(IDC_LIST, OnDblclkList)
vc6: afx_msg void OnDblclkList(NMHDR* pNMHDR, LRESULT* pResult);
vc7: afx_msg void OnDblclkList(); // This is AFX_PMSG
ON_WM_COPYDATA()
vc6: afx_msg LONG OnCopyData(CWnd* pWnd, COPYDATASTRUCT* pCopyDataStruct);
vc7: afx_msg BOOL OnCopyData(CWnd* pWnd, COPYDATASTRUCT* pCopyDataStruct);
ON_NOTIFY_REFLECT_EX(NM_CUSTOMDRAW, OnCustomDraw)
vc6: void afx_msg OnCustomDraw(NMHDR* pNMHDR, LRESULT* pResult);
vc7: BOOL afx_msg OnCustomDraw(NMHDR* pNMHDR, LRESULT* pResult); // return
TRUE only when you have processed the message
ON_WM_TIMER()
vc6: afx_msg void OnTimer(int);
vc7: afx_msg void OnTimer(UINT_PTR);
Probably others too.