ChatConversation ChatConversation ChatConversation ChatConversation Class

Definition

Represents a conversation in a chat client.

public : sealed class ChatConversation : IChatConversation, IChatConversation2, IChatItempublic sealed class ChatConversation : IChatConversation, IChatConversation2, IChatItemPublic NotInheritable Class ChatConversation Implements IChatConversation, IChatConversation2, IChatItem// You can use this class in JavaScript.
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

Call the ChatMessageStore.GetConversationAsync or ChatMessageStore.GetConversationFromThreadingInfoAsync method to get an instance of this class.

Properties

CanModifyParticipants CanModifyParticipants CanModifyParticipants CanModifyParticipants

Gets or sets a boolean that indicates whether participants can be modified or not.

public : PlatForm::Boolean CanModifyParticipants { get; set; }public bool CanModifyParticipants { get; set; }Public ReadWrite Property CanModifyParticipants As bool// You can use this property in JavaScript.
Value
PlatForm::Boolean bool bool bool

A boolean that indicates whether participants can be modified or not.

Additional features and requirements
Device family
Windows 10 (introduced v10.0.10586.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced v2)

HasUnreadMessages HasUnreadMessages HasUnreadMessages HasUnreadMessages

Gets a Boolean value indicating if there are unread messages in the ChatConversation.

public : PlatForm::Boolean HasUnreadMessages { get; }public bool HasUnreadMessages { get; }Public ReadOnly Property HasUnreadMessages As bool// You can use this property in JavaScript.
Value
PlatForm::Boolean bool bool bool

A Boolean value indicating if there are unread messages in the ChatConversation.

Id Id Id Id

Gets the unique identifier for the ChatConversation.

public : PlatForm::String Id { get; }public string Id { get; }Public ReadOnly Property Id As string// You can use this property in JavaScript.
Value
PlatForm::String string string string

The unique identifier for the ChatConversation.

IsConversationMuted IsConversationMuted IsConversationMuted IsConversationMuted

Gets or sets a Boolean value indicating if the ChatConversation is muted.

public : PlatForm::Boolean IsConversationMuted { get; set; }public bool IsConversationMuted { get; set; }Public ReadWrite Property IsConversationMuted As bool// You can use this property in JavaScript.
Value
PlatForm::Boolean bool bool bool

A Boolean value indicating if the ChatConversation is muted.

ItemKind ItemKind ItemKind ItemKind

Gets the item kind.

public : ChatItemKind ItemKind { get; }public ChatItemKind ItemKind { get; }Public ReadOnly Property ItemKind As ChatItemKind// You can use this property in JavaScript.
Additional features and requirements
Device family
Windows 10 Anniversary Edition (introduced v10.0.14393.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v3)

MostRecentMessageId MostRecentMessageId MostRecentMessageId MostRecentMessageId

Gets the ID of the most recent message in the conversation.

public : PlatForm::String MostRecentMessageId { get; }public string MostRecentMessageId { get; }Public ReadOnly Property MostRecentMessageId As string// You can use this property in JavaScript.
Value
PlatForm::String string string string

The ID of the most recent message in the conversation.

Participants Participants Participants Participants

Gets a list of all the participants in the conversation.

public : IVector<string> Participants { get; }public IList<string> Participants { get; }Public ReadOnly Property Participants As IList<string>// You can use this property in JavaScript.
Value
IVector<PlatForm::String> IList<string> IList<string> IList<string>

A list of all the participants in the conversation.

Subject Subject Subject Subject

Gets or sets the subject of a group conversation.

public : PlatForm::String Subject { get; set; }public string Subject { get; set; }Public ReadWrite Property Subject As string// You can use this property in JavaScript.
Value
PlatForm::String string string string

The subject of a group conversation.

ThreadingInfo ThreadingInfo ThreadingInfo ThreadingInfo

Gets the threading info for the ChatConversation.

public : ChatConversationThreadingInfo ThreadingInfo { get; }public ChatConversationThreadingInfo ThreadingInfo { get; }Public ReadOnly Property ThreadingInfo As ChatConversationThreadingInfo// You can use this property in JavaScript.

Methods

DeleteAsync() DeleteAsync() DeleteAsync() DeleteAsync()

Asynchronously deletes all of the messages in the ChatConversation and the conversation itself.

public : IAsyncAction DeleteAsync()public IAsyncAction DeleteAsync()Public Function DeleteAsync() As IAsyncAction// You can use this method in JavaScript.
Returns

An async action that indicates when the delete has completed.

Additional features and requirements
Device family
Windows 10 (introduced v10.0.10240.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)
Capabilities
blockedChatMessages

GetMessageReader() GetMessageReader() GetMessageReader() GetMessageReader()

Gets the ChatMessageReader for this ChatConversation.

public : ChatMessageReader GetMessageReader()public ChatMessageReader GetMessageReader()Public Function GetMessageReader() As ChatMessageReader// You can use this method in JavaScript.
Returns

MarkMessagesAsReadAsync() MarkMessagesAsReadAsync() MarkMessagesAsReadAsync() MarkMessagesAsReadAsync()

Asynchronously marks all the messages in the conversation as read.

public : IAsyncAction MarkMessagesAsReadAsync()public IAsyncAction MarkMessagesAsReadAsync()Public Function MarkMessagesAsReadAsync() As IAsyncAction// You can use this method in JavaScript.
Returns

An async action indicating that the operation has completed.

See Also

MarkMessagesAsReadAsync(DateTime) MarkMessagesAsReadAsync(DateTime) MarkMessagesAsReadAsync(DateTime) MarkMessagesAsReadAsync(DateTime)

Asynchronously marks all the messages in the conversation before the specified DateTime as read.

public : IAsyncAction MarkMessagesAsReadAsync(DateTime value)public IAsyncAction MarkMessagesAsReadAsync(DateTimeOffset value)Public Function MarkMessagesAsReadAsync(value As DateTimeOffset) As IAsyncAction// You can use this method in JavaScript.
Parameters
value
DateTime DateTimeOffset DateTimeOffset DateTimeOffset

Mark all messages before this DateTime as read.

Returns

An async action indicating that the operation has completed.

See Also

NotifyLocalParticipantComposing(String, String, Boolean) NotifyLocalParticipantComposing(String, String, Boolean) NotifyLocalParticipantComposing(String, String, Boolean) NotifyLocalParticipantComposing(String, String, Boolean)

Call this to indicate that the local participant has started or has completed typing.

public : void NotifyLocalParticipantComposing(PlatForm::String transportId, PlatForm::String participantAddress, bool isComposing)public void NotifyLocalParticipantComposing(String transportId, String participantAddress, Boolean isComposing)Public Function NotifyLocalParticipantComposing(transportId As String, participantAddress As String, isComposing As Boolean) As void// You can use this method in JavaScript.
Parameters
transportId
PlatForm::String String String String

Specifies the ChatMessageTransport to use.

participantAddress
PlatForm::String String String String

The address of the remote participant.

isComposing
bool Boolean Boolean Boolean

TRUE if the local participant is typing, otherwise FALSE.

NotifyRemoteParticipantComposing(String, String, Boolean) NotifyRemoteParticipantComposing(String, String, Boolean) NotifyRemoteParticipantComposing(String, String, Boolean) NotifyRemoteParticipantComposing(String, String, Boolean)

Locally triggers the event that indicates that a remote participant is typing.

public : void NotifyRemoteParticipantComposing(PlatForm::String transportId, PlatForm::String participantAddress, bool isComposing)public void NotifyRemoteParticipantComposing(String transportId, String participantAddress, Boolean isComposing)Public Function NotifyRemoteParticipantComposing(transportId As String, participantAddress As String, isComposing As Boolean) As void// You can use this method in JavaScript.
Parameters
transportId
PlatForm::String String String String

Specifies the ChatMessageTransport to use.

participantAddress
PlatForm::String String String String

The address of the remote participant.

isComposing
bool Boolean Boolean Boolean

TRUE if the remote participant is typing, otherwise FALSE.

SaveAsync() SaveAsync() SaveAsync() SaveAsync()

Asynchronously saves the ChatConversation.

public : IAsyncAction SaveAsync()public IAsyncAction SaveAsync()Public Function SaveAsync() As IAsyncAction// You can use this method in JavaScript.
Returns

An async action indicating that the operation has completed.

Additional features and requirements
Device family
Windows 10 (introduced v10.0.10240.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)
Capabilities
blockedChatMessages

Events

RemoteParticipantComposingChanged RemoteParticipantComposingChanged RemoteParticipantComposingChanged RemoteParticipantComposingChanged

Occurs when the remote user has started or finished typing.

public : event TypedEventHandler RemoteParticipantComposingChanged<ChatConversation,  RemoteParticipantComposingChangedEventArgs>public event TypedEventHandler RemoteParticipantComposingChanged<ChatConversation,  RemoteParticipantComposingChangedEventArgs>Public Event RemoteParticipantComposingChanged<ChatConversation,  RemoteParticipantComposingChangedEventArgs>// You can use this event in JavaScript.