Office Communicator 使用 C# API 自动接受呼叫
当有人呼叫“我”开始视频通话时,是否有办法自动接听使用 C# Api 编程的呼叫?
使用 API 启动视频通话很简单:
var contactArray = new ArrayList();
contactArray.Add("[email protected]");
object[] sipUris = new object[contactArray.Count];
int currentObject = 0;
foreach (object contactObject in contactArray)
{
sipUris[currentObject] = contactObject;
currentObject++;
}
var communicator = new Messenger();
communicator.OnIMWindowCreated += new DMessengerEvents_OnIMWindowCreatedEventHandler(communicator_OnIMWindowCreated);
IMessengerAdvanced msgrAdv = communicator as CommunicatorAPI.IMessengerAdvanced;
if (msgrAdv != null)
{
try
{
object obj = msgrAdv.StartConversation(CommunicatorAPI.CONVERSATION_TYPE.CONVERSATION_TYPE_VIDEO, sipUris, null, "Conference Wall CZ - Conversation", "1", null);
}
catch (COMException ex)
{
Console.WriteLine(ex.Message);
}
}
但另一方面我想自动接受此通话......
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
据我所知,OC 是不可能的,大概是出于安全原因。我最终做的是让远程机器人给我打电话,然后我接听。因此,我与我有服务监听的消息帐户聊天“开始视频”。该服务给我打电话,然后我手动接听。
Not possible with OC so far as I've found, presumably for security reasons. What I ended up doing was having the remote bot call me then I answer. So I chat "start video" to a messenger account that I've got a service listening to. That service calls me, then I answer it on my side manually.