Hi;
I know how to use EnumWindows and EnumWindowsProc in cpp,
but i don;t know how to define the prototype of th EnumWindowsProc
in MFC dialog base application,
anyone can give me a sample code?
Thanks
Printable View
Hi;
I know how to use EnumWindows and EnumWindowsProc in cpp,
but i don;t know how to define the prototype of th EnumWindowsProc
in MFC dialog base application,
anyone can give me a sample code?
Thanks
I don't see the problem, AFAIAA the prototype for EnumWindowsProc is no different using MFC than in plain Windows SDK.
What problems do you get?
Dave
thanks for you reply,
but i still wonder how shall i do..
1. Where shall i put the EnumWindowsProc function? A new class? View class?
or as a global?
2. How shall i define the EnumWindowsProc? as BOOL CALLBACK?
Thanks
You can put it wherever you like. If you make it a class member, you must make it static.
It is declared as:
BOOL CALLBACK EnumWindowsProc(HWND hwnd, LPARAM lParam);
Of course, you don't have to call it EnumWindowsProc!
Dave