Guide.ShowComposeMessage Method
Shows the Compose Message user interface. A gamer uses this user interface to write messages to other gamers.
Namespace: Microsoft.Xna.Framework.GamerServices
Assembly: Microsoft.Xna.Framework.GamerServices (in microsoft.xna.framework.gamerservices.dll)
public static void ShowComposeMessage ( PlayerIndex player, string text, IEnumerable<Gamer> recipients )
Parameters
- player
- Type: PlayerIndex
Gamer composing the message. - text
- Type: String
Text of the message. - recipients
- Type: IEnumerable<Gamer>
Collection of gamers receiving the message.If this is null, the Select Gamertag user interface is displayed.
| Exception type | Condition |
|---|---|
| ArgumentOutOfRangeException | For Windows applications, this exception is thrown if player is not PlayerIndex.One. |
| ArgumentException | The message text is null, empty, or exceeds 200 characters. This exception also is thrown if any recipients have a value of null or if there are more than 100 recipients. |
| NotSupportedException | This method is not supported on the current platform. |
Windows Phone Specific Information |
|---|
| This method cannot be used on Windows Phone. If called, it throws a NotSupportedException. |
Best Practice |
|---|
|
You can check GamerPrivileges.AllowCommunication to determine if a player is allowed to send and receive communications before displaying a menu option that would call this method. |
Community Additions
ADD
Show:
Windows Phone Specific Information
Best Practice