3
我開發了一個使用Lync API的Windows應用程序。我的客戶想要禁止來電到這個應用程序。所以我添加了一些這樣的東西。我能夠切斷電話,但也有能夠做到這一點不允許傳入呼叫Lync Api或禁用傳入呼叫的聲音
private void ClientInitialized(IAsyncResult result)
{
try
{
//registers for conversation related events
//these events will occur when new conversations are created (incoming/outgoing) and removed
client.ConversationManager.ConversationAdded += ConversationManager_ConversationAdded;
client.ConversationManager.ConversationRemoved += ConversationManager_ConversationRemoved;
}
catch (Exception ex)
{
MessageBox.Show("Problem in adding/removing conversation", "Bella IVIS", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
void ConversationManager_ConversationAdded(object sender, ConversationManagerEventArgs e)
{
try
{
var _client = client;
if (e.Conversation.State == ConversationState.Active)
{
for (int intLoop = 0; intLoop < _client.ConversationManager.Conversations.Count; intLoop++)
{
_client.ConversationManager.Conversations[intLoop].End();
}
_client = null;
return;
}
}
}
ConversationAdded是在對話添加後。您想在添加對話之前查看以確定在完成添加之前將其完全阻止/靜音 – user3036342 2014-12-04 12:19:49
是否有任何要查找的事件名稱 – Vivekh 2014-12-04 12:24:13
這是特定於此客戶端(端點)還是用戶?如果是用戶,您可以關閉服務器端用戶的audiovideo功能。舊文章可能仍然是相關的:http://jackiechen.org/2012/02/13/disable-audiovideo-features-in-lync-client/ – 2014-12-04 19:13:08