MessageSentEventArgs.Content Property
Returns the content of the processed message.
Namespace: DevExpress.AIIntegration.Blazor.Chat
Assembly: DevExpress.AIIntegration.Blazor.Chat.v25.2.dll
NuGet Package: DevExpress.AIIntegration.Blazor.Chat
Declaration
public string Content { get; }
Property Value
| Type | Description |
|---|---|
| String | Message text content. |
Remarks
Use the Content property to access the content of the message, currently being processed.
<DxAIChat MessageSent="MessageSent"
FileUploadEnabled="true" />
@code {
async Task MessageSent(MessageSentEventArgs args) {
if(args.Files != null && args.Files.Count > 0) {
var fileNames = args.Files.Select(x => x.Name);
var response = $"Processed message content: {args.Content}.{System.Environment.NewLine}";
response += $"The message contains {args.Files.Count} attached file(s):{System.Environment.NewLine}";
response += string.Join(System.Environment.NewLine, fileNames);
await args.Chat.SendMessage(response, ChatRole.Assistant);
}
}
}
Related GitHub Examples
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Content property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.