IWMSServer.Players (C#)

The Players object retrieves an IWMSPlayersIWMSPlayers Object (C#) containing a collection of IWMSPlayer objects. Each object in the collection contains specific information about a connected client.

IWMSPlayers = IWMSServer.Players;

Property Value

An IWMSPlayers collection.

Remarks

This property is read-only. Each IWMSPlayer object contains client information such as the IP address, the user name, and so on. For more information about the client information collected by the server, see the IWMSPlayerIWMSPlayer Object (C#).

Example

using Microsoft.WindowsMediaServices.Interop;
using System.Runtime.InteropServices;

// Declare variables.
WMSServer   Server;
IWMSPlayers Players;

try {
    // Create a new WMSServer object.
    Server = new WMSServerClass();

    // Retrieve a list of currently connected clients.
    Players = Server.Players;
}
catch (COMException comExc) {
    // TODO: Handle COM exceptions.
}
catch (Exception e) {
    // TODO: Handle exceptions.
}

Requirements

Reference: Add a reference to Microsoft.WindowsMediaServices.

Namespace: Microsoft.WindowsMediaServices.Interop.

Assembly: Microsoft.WindowsMediaServices.dll.

Library: WMSServerTypeLib.dll.

Platform: Windows Server 2003 family, Windows Server 2008 family.

See Also

Reference

IWMSPlayer Object (C#)

IWMSPlayers Object (C#)

IWMSServer Object (C#)