lo que yo queria es si por ejemplo tengo un handle de una ventana y quiero saber si el elemento hijo que tiene el foco es es tipo TEXTBOX (como combobox, textbox, etc)para que yo hacerle un sendmessage de GETTEXT. creo es esto pero no estoy seguro, y si es entonces una explicada
'Funcion que devuelve el control Hijo que tiene el foco
Private Function GetFocusEx() As Long
Dim hFore As Long, hFocus As Long
'hFocus = GetFocus
'If hFocus = 0 Then
hFore = GetForegroundWindow()
Call AttachThreadInput(GetWindowThreadProcessId(hFore, 0&), GetCurrentThreadId, True)
hFocus = GetFocus
Call AttachThreadInput(GetWindowThreadProcessId(hFore, 0&), GetCurrentThreadId, False)
'End If
GetFocusEx = hFocus
End Function