I'm trying to start a Lync Conversation which appears to be working on my local environment which is also where Microsoft Lync is installed. Now When I try to move this code onto a website hosted on a server, and then try to run this code on a browser from my local computer, it won't run. I get the error, "microsoft.Lync.Model.clientNotFoundException". I'm guessing its because its looking for the Lync Client on the server and not on the User's local computer? How do I get it to look for the client on the User's computer? Thanks!
using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Lync.Model.Extensibility;
using Microsoft.Lync.Model;
namespace PlusLyncDial
{
public class LyncDial
{
public static void DialNumber(string number)
{
number = number.Trim();
if(number[0]!='1')
{
number = "1" + number;
}
List<string> participants = new List<string>();
participants.Add("tel:+" + number);
LyncClient.GetClient();
// Start the conversation.
LyncClient.GetAutomation().BeginStartConversation(
AutomationModalities.Audio,
participants,
null,
(ar) =>
{
try
{
ConversationWindow newWindow = LyncClient.GetAutomation().EndStartConversation(ar);
}
catch { }
},
null);
}
}
}