• 软件测试技术
  • 软件测试博客
  • 软件测试视频
  • 开源软件测试技术
  • 软件测试论坛
  • 软件测试沙龙
  • 软件测试资料下载
  • 软件测试杂志
  • 软件测试人才招聘
    暂时没有公告

字号: | 推荐给好友 上一篇 | 下一篇

Readabyte,integerorlongfrommemory

发布: 2007-5-25 09:24 | 作者: shuwork | 来源: 互联网 | 查看: 28次 | 进入软件测试论坛讨论

领测软件测试网 Date: 6/17/2000
Versions: VB4/32 VB5 VB6 Level: Intermediate
Author:
vb2themax.com">The VB2TheMax Team

Private Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (dest As _
    Any, source As Any, ByVal bytes As Long)

' read a byte from memory

Function PeekB(ByVal address As Long) As Byte
    CopyMemory PeekB, ByVal address, 1
End Function

' read an integer from memory

Function PeekI(ByVal address As Long) As Integer
    CopyMemory PeekI, ByVal address, 2
End Function

' read a Long value from memory

Function PeekL(ByVal address As Long) As Long
    CopyMemory PeekL, ByVal address, 4
End Function

延伸阅读

文章来源于领测软件测试网 https://www.ltesting.net/