Returns the IMessengerService object for the primary service for the primary client. Scriptable.
HRESULT PrimaryService( [out, retval] IDispatch** ppService );
Address of a pointer to an IMessengerService interface that represents the primary service.
Returns one of the following values. For managed code applications, these return values are received in the form of a COMException.
ppService is a null pointer.
The primary service is the service used when the IMessenger::AutoSignin method is called. This object can be obtained from an active Messenger object. It is not necessary that a user is logged on when the PrimaryService property is queried. To gain access to this property, you must first instantiate an IMessenger and then a IMessengerServices object.
The following example code uses an instance of the IMessenger object, communicator, to retrieve a collection of IMessengerService objects. The communicatorServices property, PrimaryService, is queried to retrieve the IMessengerService object representing the primary service used by the logged-on user.
IMessengerServices communicatorServices; IMessengerService thisService; communicatorServices = (IMessengerServices)communicator.Services; if (communicatorServices != null) thisService = (IMessengerService)communicatorServices.PrimaryService;
Requires Microsoft DirectX 9.0, C Runtime libraries (msvcm80.dll) on Microsoft Windows© Vista, Microsoft Windows XP Service Pack 1 (SP1) or later, or Microsoft Windows 2000 with Service Pack 4 (SP4). Any Communicator-imposed restrictions apply. .
Requires Microsoft Office Communications Server 2007, AV MCU (for Media Support), Media Relay (for NAT/Firewall traversal) on Microsoft Office Communications Server 2007.
Microsoft Office Communicator 2007 Automation API
- IDL file