New to Telerik UI for WinUI? Download free 30-day trial

Text Message

The TextMessage class is intended to be used for sending a simple string type message. It exposes the following properties:

  • Text—The Text property gets or sets the text that will be displayed in the TextMessage instance.
  • Author—The Author property provides information about the author of the text message.
  • Status—This property allows you to specify a status for the TextMessage instance.
  • CreationDate—This property provides the ability to specify a DateTime object for the creation date of the text message.

In order to display a status for the message, the CreationDate property needs to be set as well.

Defining a TextMessage

var textMessage = new TextMessage(this.currentAuthor, "Some text message", "sent", DateTime.Now); 
textMessage.InlineViewModel.StatusVisibility = Visibility.Visible; 
 
this.chat.AddMessage(textMessage); 
RadChat with TextMessage

RadChat with TextMessage

In this article
Not finding the help you need?