Código [Seleccionar]
Option Explicit
Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Declare Function FindWindowEx Lib "user32" Alias "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, ByVal lpsz2 As String) As Long
Private Sub Command1_Click()
Dim hWndMain As Long
Dim hWndChild As Long
Dim hWndAnalizar As Long
hWndMain = FindWindow("PiriformCCleaner", "Piriform CCleaner")
If hWndMain = 0 Then
MsgBox "Ccleaner sin Ejecutar"
Else
hWndChild = FindWindowEx(hWndMain, 0, "#32770", vbNullString)
hWndAnalizar = FindWindowEx(hWndChild, 0, "Button", "&Analizar")
If hWndAnalizar = 0 Then
MsgBox "La Opcion Limpiador no está Seleccionada"
Else
MsgBox hWndAnalizar
End If
End If
End Sub