Question

I'm writing a custom light-weight in/out board (AKA Status, Presence, etc.) application using the Microsoft Lync 2010 API. It needs to run after startup/login but I've ran into a problem when I login after I start/restart the machine. I get the following error from the LyncClient.GetClient method

System.Runtime.InteropServices.COMException (0x800706BE): The remote procedure call failed. (Exception from HRESULT: 0x800706BE) at Microsoft.Office.Uc.IUCOfficeIntegration.GetInterface(String _version, OIInterface _interface) at Microsoft.Lync.Model.LyncClient.GetClient()

My application is a ClickOnce application that runs from a network drive. It's available only in Online mode. The .application file is called from a batch file that is run from netlogon. It works fine if I run the batch file after my computer has been running for a while. It also works if I log out and then log back in. Therefore I'm assuming that there is a service required that has not yet started when the LyncClient.GetClient method is called.

Was it helpful?

Solution

I would agree that it's a service that you're waiting for, and would hazard a guess at the "Remote Procedure Call (RPC)" service. This is the service that enables COM communication (i.e. it handles COM activation requests, among other things).

It's awkward to test this, as Service Control Manager doesn't let you shut the service down - it's a critical service as large swathes of Windows rely on COM.

To test, you could check the startup status of the service in code, and then only initialise Lync when that service is started.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top