New to Telerik UI for .NET MAUIStart a free 30-day trial

Provides context for the PromptRequestCommand.

Definition

Namespace:Telerik.Maui.Controls.DataGrid

Assembly:Telerik.Maui.Controls.dll

Syntax:

C#
public class DataGridPromptRequestCommandContext

Inheritance: objectDataGridPromptRequestCommandContext

Constructors

Initializes a new instance of the DataGridPromptRequestCommandContext class.

C#
public DataGridPromptRequestCommandContext(string prompt, Action<string> onResponseSet = null, Action<bool> onHasErrorSet = null)
Parameters:promptstring

The prompt text from the user.

onResponseSetAction<string>

Optional callback invoked when the Response property is set.

onHasErrorSetAction<bool>

Optional callback invoked when the HasError property is set.

Properties

Gets or sets a value indicating whether an error occurred during processing.

C#
public bool HasError { get; set; }

Gets the prompt text from the user.

C#
public string Prompt { get; }

Gets or sets the JSON request sent to the AI model.

C#
public string RequestJson { get; set; }

Gets or sets the response text.

C#
public string ResponseJson { get; set; }