este foro esta plagado de ejemplos de esa api, ya he respondiod varias veces esto.
por ejemplo para hacerle click al boton "Aceptar" del dilogo "Ejecutar" de windows.
Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Integer
Private Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As Integer, ByVal hWnd2 As Integer, ByVal lpsz1 As String, ByVal lpsz2 As String) As Integer
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Integer, ByVal wMsg As Integer, ByVal wParam As Integer, ByVal lParam As String) As Integer
Private Const BM_CLICK = &HF5
Private Sub Form_Load()
Dim vPadre As Long
Dim vHijo1 As Long
vPadre = FindWindow("#32770", "Ejecutar")
vHijo1 = FindWindowEx(vPadre, 0&, "Button", "Aceptar")
Call SendMessage(vHijo1, BM_CLICK, 0, vbNullString)
End Sub
saludos.