Large text (more than 5000 words or more) can't save through HTML editor, I'm getting below error. please have a look error below
[2021-11-03T09:20:12.523Z] Error: Connection disconnected with error 'Error: Server returned an error on close: Connection closed with an error.'.
<RadzenHtmlEditor Style="height: 250px; margin-bottom: 1rem;"
@bind-Value="@Value"
Disabled="@IsSaving"
Change="@(OnChange)" />
private async Task OnChange(string selectedValue) // selectedValue coming null for large text but for small text like 2000 words is fine.
{
try {
if (string.IsNullOrEmpty(PropertyName) || string.IsNullOrEmpty(selectedValue))
return;
// Do stuff
}
catch (Exception e)
{
}
}
I too ran into this old chestnut yesterday but was able to resolve using Microsoft's suggestion of streaming the content back with a JS interop as per this:
This doesn't require changing the message size and you can configure the max size per field..
but I was unable to do this with RadzenTextarea as it didn't like me using @ref - it returned this error:
CS0029 Cannot implicitly convert type 'Radzen.Blazor.RadzenTextArea' to 'Microsoft.AspNetCore.Components.ElementReference'
I'm happy with my solution but maybe Radzen Team can make @ref work for RadzenTextArea or the HTML field for future?