如何用VB或读取QQ消息

如何用VB或读取QQ消息,第1张

VB读取QQ消息,依次读取QQ消锋岩行息窗口

01 Private Declare Function GetWindow Lib "user32" (ByVal hwnd As Long, ByVal wCmd As Long) As Long

02 Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVallpWindowName As String) As Long

03 Private Declare Function GetWindowText Lib "user32" Alias "GetWindowTextA" (ByVal hwnd As Long, ByVallpString As String, ByVal cch As Long) As Long

04 Private Declare Function GetClassName Lib "user32" Alias "GetClassNameA" (ByVal hwnd As Long, ByVallpClassName As String, ByVal nMaxCount As Long) As Long

05Private Const GW_CHILD = 5

06Private Const GW_HWNDNEXT = 2

07Private Sub Command1_Click()

08Dim hWin As Long

09Dim strText As String

10Dim strClass As String

11Dim arr(1 To 5) As String

12Dim flag As Integer

13Dim length As Integer

14flag = 1

15List1.Clear

16'第一个QQ消银哗息枣扮窗口

17hWin = FindWindow("CTXOPConntion_Class", vbNullString)

18If hWin = 0 Then Exit Sub

19Do

20strText = String$(50, vbNullChar)

21GetWindowText hWin, strText, Len(strText)

22strText = Left$(strText, InStr(strText, vbNullChar) - 1)

23If InStr(strText, "OP_") = 1 Then

24strText = Mid$(strText, 4)

25List1.AddItem strText

26arr(flag) = strText

27flag = flag + 1

28End If

29Do

30'下一个窗口

31hWin = GetWindow(hWin, GW_HWNDNEXT)

32If hWin = 0 Then Exit Do

33strClass = String$(50, vbNullChar)

34GetClassName hWin, strClass, Len(strClass)

35strClass = Left$(strClass, InStr(strClass, vbNullChar) - 1)

36Loop While strClass <>"CTXOPConntion_Class"

37Loop While hWin

38List1.Text = strText

39End Sub

在电脑浏览器里面关镇正键。

在浏览器里面输入QQ互联管理中心,找到QQ官网,用清晌自己的QQ登录,将鼠标御巧放到头像右侧的小三角图标上面,在出现的菜单中点击授权管理选项,然后就可以取消授权了。

手机的设置里面没有的功能可以在电脑的互联管理中心去找。


欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/yw/12288361.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2023-05-24
下一篇 2023-05-24

发表评论

登录后才能评论

评论列表(0条)

保存