付出最大努力,追求最高成就,享受最佳生活,收获无悔人生
2009-9-8 12:28:55 阅读(69) 评论(0)
Private Declare Function TransparentBlt Lib "msimg32.dll" _
(ByVal hdcDest As Long, _
ByVal nXOriginDest As Long, _
ByVal nYOriginDest As Long, _
ByVal nWidthDest As Long, _
ByVal nHeightDest As Long, _
ByVal hdcSrc As Long, _
2009-8-13 10:07:05 阅读(0) 评论(0)
2009-8-11 13:23:29 阅读(15) 评论(0)
Option Explicit
Private Declare Function PlgBlt Lib "gdi32" (ByVal hdcDest As Long, _
lpPoint As POINTAPI, ByVal hdcSrc As Long, ByVal nXSrc As Long, _
ByVal nYSrc As Long, ByVal nWidth As Long, ByVal nHeight As Long, _
ByVal hbmMask As Long, ByVal xMask As Long, ByVal yMask As Long) As Long
Private Type POINTAPI
x As Long
y As Long
End Type
Const pi = 3.14159265358979
2009-7-6 19:33:25 阅读(8) 评论(0)
Private Function MIM(Arr As Variant) '升序排列
Dim i, j As Long
Dim a As Variant, b As Variant
For i = 0 To UBound(Arr)
For j = i + 1 To UBound(Arr)
a = Arr(i)
b = Arr(j)
If Arr(i) > Arr(j) Then
Arr(i) = b
2009-7-4 16:25:13 阅读(0) 评论(0)
2009-7-4 4:36:59 阅读(1) 评论(0)
Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo As Long)
Const theScreen = 0
Const theForm = 1
Private Sub Command1_Click()
Call keybd_event(vbKeySnapshot, theForm, 0, 0)
'若theForm改成theScreen则Copy整个Screen
DoEvents
SavePicture
2009-6-18 9:14:06 阅读(1) 评论(0)
2009-6-12 6:58:17 阅读(5) 评论(0)
Option Explicit
Private Type cp
wp As Single
hp As Single
tp As Single
lp As Single
End Type
Dim ap() As cp
Private Sub Form_Load()
ReDim ap(0 To Controls.Count - 1) As cp
ai
Me.Move 0, 0
End Sub
Private Sub Form_Resize()
Dim i As Integer
For i = 0 To Controls.Count - 1
Controls(i).Move ap(i).lp
2009-6-9 8:07:47 阅读(8) 评论(0)
Option Explicit
Private Const GW_HWNDNEXT = 2
Private Declare Function GetWindowThreadProcessId Lib "user32" (ByVal hwnd As Long, lpdwProcessId As Long) As Long
Private Declare Function GetParent Lib "user32" (ByVal hwnd As Long) As Long
Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As Long, ByVal lpWindowName As Long) As Long
Private
2009-6-9 7:58:29 阅读(33) 评论(0)
'模块
Option Explicit
Public Declare Function SetWindowsHookEx Lib "user32" Alias "SetWindowsHookExA" (ByVal idHook As Long, ByVal lpfn As Long, ByVal hmod As Long, ByVal dwThreadId As Long) As Long
Public Declare Function UnhookWindowsHookEx Lib "user32" (ByVal hHook As Long) As Long
Public Declare Function GetKeyState Lib "user32" (ByVal nVirtKey As Long) As Integer
Public Declare