易截截图软件、单文件、免安装、纯绿色、仅160KB

VB写注册表启动项


    Private Sub Form_Load()
        Set w = CreateObject("wscript.shell")
        w.regwrite "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run\" & App.EXEName, App.Path & "\" & App.EXEName & ".exe"
   End Sub


相关文档:

vb做的大小写字母转换器

'大小写字母转换器vb
'界面包括 command、command1、command2、command3 和一个 text 文本框
'command 为“互转”按钮,command1 为“转大”按钮,command2 为“转小”按钮,command3 为“清除”按钮
Private Sub Command_Click()
Dim i As Integer, n As Integer
Dim x As S ......

vb字符串在内存中的分布?

据说vb6中,字 符串以以UNICODE方式存储,所以
Private Type UDT
lngM1 As Long
lngM2 As Long
strM3 As String * 18
strM4 As String * 8
lngM5 As Long
End Type
Private Sub Command4_Click()
Dim tmp As UDT
With tmp
.lngM1 = 1
.lngM2 = 2
' .str ......

vb 锁定鼠标到某一位置

Private Declare Function ClipCursor Lib "user32" (lpRect As Any) As Long
Private Type RECT
    Left As Long
    Top As Long
    Right As Long
    Bottom As Long
End Type
Private Sub Command1_Click() '锁定鼠标 到某一位置
   ......

VB 长整型和字节数组的转换问题 (LongByte)

VB 长整型和字节数组的转换问题 (Long<>Byte)
Posted by JiaJia 17 March,2009 (0)Comment
用到的API声明:
Private Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (Destination As Any, Source As Any, ByVal Length As Long)
Long2Byte
Dim TempLng As Long
Dim TempBytes(0 To 3) As Byte ......

VB为自己的程序设定消息(可接收处理)


VB为自己的程序设定消息(可接收处理)
Posted by JiaJia 5 March,2009 (0)Comment
  用API函数 SetWindowLong 指定处理消息的窗口过程为自定义的函数 WindowProc,捕获消息ID为 WM_USER+1 的自定义消息或系统消息。并且,为了保证窗口能正确的响应消息,需要保存原来默认的窗口过程并在自定义函数WindowProc中调用。 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号