蓝剑的博客

付出最大努力,追求最高成就,享受最佳生活,收获无悔人生

 
 
 
 
 
 
模块内容加载中...
 
 
 
 
 

日历

 
 
模块内容加载中...
 
 
 
 
 
 
 
列表加载中...
 
 
 
 
 

天气

 
 
模块内容加载中...
 
 
 
 
 
 
 
 
模块内容加载中...
 
 
 
 
 
 
 

TransparentBlt图片透明

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, _


阅读全文>>

阅读(69) | 评论(0) | 阅读全文>>

flash右键菜单

2009-8-13 10:07:05 阅读(0) 评论(0)

my_cm = new ContextMenu();// 申明一个新的菜单对象
my_cm.hideBuiltInItems();// 屏敞当前的右键菜单
my_cm.customItems.push(new ContextMenuItem("lianzy的日志", menu1));// 创建一个新的子菜单,名为“”,并设置menu1为响应函数
function menu1(obj, item) {
 trace("lianzy的日志");
 getURL(http://lianzy.blog.163.com, "_blank");// “”的响应函数具体内容
}
_root.menu = my_cm;// 将当前定义的菜单绑定到主场景的右键菜单
阅读全文>>

阅读(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


阅读全文>>

阅读(15) | 评论(0) | 阅读全文>>

数组排序

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


阅读全文>>

阅读(8) | 评论(0) | 阅读全文>>

Mdi最大最小按钮不可用

2009-7-4 16:25:13 阅读(0) 评论(0)

Private   Declare   Function   SetWindowLong   Lib   "user32"   _  
  Alias   "SetWindowLongA"   (ByVal   hwnd   As   Long,   ByVal   _  
  nIndex   As   Long,   ByVal   dwNewLong   As   Long)   As   Long  
   
  Private   Declare   Function   GetWindowLong   Lib   "user32"   _  
阅读全文>>

阅读(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


阅读全文>>

阅读(1) | 评论(0) | 阅读全文>>

生成guid

2009-6-18 9:14:06 阅读(1) 评论(0)

Private Declare Function CoCreateGuid Lib "ole32" (id As Any) As Long
'生成guid
Public Function CreateGUID() As String
    Dim id(0 To 15) As Byte
    Dim Cnt As Long, GUID As String
    If CoCreateGuid(id(0)) = 0 Then
    For Cnt = 0 To 15
        CreateGUID = CreateGUID + IIf(id(Cnt) < 16, "0", "") + Hex$(id(Cnt))
阅读全文>>

阅读(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


阅读全文>>

阅读(5) | 评论(0) | 阅读全文>>

把外部程序作为MDI窗口打开

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


阅读全文>>

阅读(8) | 评论(0) | 阅读全文>>

键盘鼠标勾子

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


阅读全文>>

阅读(33) | 评论(0) | 阅读全文>>

查看所有日志>>

 
 
 
 
 
 
 
 

 lianzy

广东 广州 射手座

 发消息  写留言

 
博客等级加载中...
今日访问加载中...
总访问量加载中...
最后登录加载中...
 
 
 
 
 

心情随笔

 
 
心情随笔列表加载中...
 
 
 
 
 
模块内容加载中...
 我要留言
 
 
 
留言列表加载中...
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2009