|
-
Aug 25th, 2000, 01:57 PM
#1
Thread Starter
New Member
This doesn't work. Help!!!
Something is wrong with parameter's I'm passing to the GetDC or the BitBlt function.
_________________________________________________-
Declare Function FindWindow Lib "user32" alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Declare Function GetDC Lib "user32" (ByVal hwnd As Long) As Long
Declare Function GetWindowDC Lib "user32" (ByVal hwnd As Long) As Long
Declare Function BitBlt Lib "gdi32" _
(ByVal hDestDC As Long, _
ByVal x As Long, _
ByVal y As Long, _
ByVal nWidth As Long, _
ByVal nHeight As Long, _
ByVal hSrcDC As Long, _
ByVal xSrc As Long, _
ByVal ySrc As Long, _
ByVal dwRop As Long) As Long
Private Sub Form_Load()
' Use any active window on the desktop.
hWnd_MyWindow = "This is the name of my window"
A = FindWindow(vbNullString, hWnd_MyWindow)
s = GetDC(A)
BitBlt Form1.hDC, 0, 0, Screen.Width, Screen.Height, s, 0, 0, vbSrcCopy
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|