请问各位高手有关在对话框中定时器的问题
小弟我在MFC中新建一个基于对话框的程序,然后在Dlg类InitialDlg中设置定时器:函数如下SetTimer(4,10000,TimerProc);然后我在Dlg类中添加了TimerProc函数如下:void CALLBACK EXPORT CJiayanshengDlg::TimerProc(
HWND hWnd, // handle of CWnd that called SetTimer
UINT nMsg, // WM_TIMER
UINT nIDEvent, // timer identification
DWORD dwTime // system time
){;//处理程序}
可是编译总是出现如下问题:error C2664: 'SetTimer ' : cannot convert parameter 3 from 'void (struct HWND__ *,unsigned int,unsigned int,unsigned long) ' to 'void (__stdcall *)(struct HWN
D__ *,unsigned int,unsigned int,unsigned long) '
None of the functions with this name in scope match the target type
Error executing cl.exe.
请问各位高手这是怎么回事,怎样解决???(不用自带的Ontimer函数)
[解决办法]
void CALLBACK EXPORT CJiayanshengDlg::TimerProc(...
==》
void CALLBACK CJiayanshengDlg::TimerProc(...