Home » WPF

[VS2005/WINCE] What can i use instead of the Function 'EnumChildWindows' on WINCE(WM 6.0) ?

Hello, Ladies&Gentleman.

I want to get a control's handle on Dialog.

But, I only have one thing information. It's control's caption.

(Already, It's finish to get the Dialog's handle) 

I don't know control's ID and control's ClassName.

In my case, what can i do? :(

Would you like to help me out?


- HelloSehee


3 Answers Found


Answer 1

Check out the following link for sample code used alternative for EnumChildWindows()


You can  use either GetDlgItem() or GetDlgCtrlID() function  depend on your input you have.



Answer 2

Thank you for your kind.

unfortunately, I want to content(method) in a thread thought i wrote as a "What can i use instead of the Function 'EnumChildWindows' on WINCE(WM 6.0)?".

However, I notice your Advice in that link.


Answer 3

Hi HelloSehee,

We can use Findwindow API to get the handle  base on its caption, see the method signature:

HWND FindWindow(
  LPCTSTR lpClassName,
  LPCTSTR lpWindowName

The second parameter is caption, the return value is the handle of the control, for more information:


Guang-Ming Bian - MSFT



<< Previous      Next >>

Microsoft   |   Windows   |   Visual Studio   |   Sharepoint   |   Azure