did the download of honestech VHS to DVD 4.0 program. but i need these program for view and not recover.
that's why i need hide some controls(the program don't have the view menu or something like that).
i have these program for capture the window handle and works:
Code:
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 Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Const BM_CLICK = &HF5
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" _
(ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long
Private Declare Function ShowWindow Lib "user32" (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long
Dim lngresult As Long
Private Sub Command1_Click()
lngresult = FindWindow(vbNullString, "honestech VHS to DVD 4.0")
If lngresult <> 0 Then
MsgBox "found"
'EnumChildProc lngresult, AddressOf EnumChildProc
Else
MsgBox "not found"
End If
'SendMessage lngresult, vbAltMask + vbKeyF4, 0, 0
ShowWindow lngresult, 0
End Sub
Private Sub Command2_Click()
ShowWindow lngresult, 1
End Sub
these program can show and hide the program, then the handle is what i need
but i only need hide some controls. that's why i found these code:
Code:
' Display the title bar text of all top-level windows. This
' task is given to the callback function, which will receive each handle individually.
' Note that if the window has no title bar text, it will not be displayed (for clarity's sake).
Private Declare Function GetWindowText Lib "user32" Alias "GetWindowTextA" (ByVal hwnd As Long, ByVal lpString As String, ByVal cch As Long) As Long
Private Declare Function GetWindowTextLength Lib "user32" Alias "GetWindowTextLengthA" (ByVal hwnd As Long) As Long
Private Declare Function ShowWindow Lib "user32" (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long
Public Function EnumChildProc(ByVal hwnd As Long, ByVal lParam As Long) As Long
Dim slength As Long, wintext As String ' title bar text length and buffer
Dim retval As Long ' return value
Static winnum As Integer ' counter keeps track of how many windows have been enumerated
winnum = winnum + 1 ' one more window enumerated....
ShowWindow hwnd, 0
EnumChildProc = 1 ' return value of 1 means continue enumeration
End Function
but these code can hide the program
can anyone advice me?