0

我想知道是否有一种简单的方法可以使用 SKYPE4COMLib.dll API 支持的文件从 Skype 的命令中加载文本。我试图让机器人触发!然后 - 有没有一种简单的方法可以将其复制到文本框中?谢谢!-Dom

4

1 回答 1

1

这是一个例子:

Imports SKYPE4COMLib
Imports System.Net

Public Class Form1
Dim valid As Boolean = False
Dim WithEvents sBot As New Skype

Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    sBot.Attach(7, False)
End Sub

Private _WaitHandle_FirstThreadDone As New System.Threading.AutoResetEvent(False)

Private Sub sBot_MessageStatus(pMessage As ChatMessage, Status As TChatMessageStatus) Handles sBot.MessageStatus
    If Status = TChatMessageStatus.cmsReceived Or Status = TChatMessageStatus.cmsSent Then

        Dim Msg As String = pMessage.Body
        Dim c As Chat = pMessage.Chat

        If Msg.StartsWith("!hello") Then
            c.SendMessage("Hello sir!")
于 2015-04-26T15:10:56.297 回答