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

Use an Inline Editor in Editor Templates

Updated on Dec 10, 2025

Environment

ProductTelerik UI for ASP.NET MVC Editor
Progress Telerik UI for ASP.NET MVC version2024.4.1112

Description

How can I use an inline Editor in an editor template and submit its value?

Solution

When you add the inline Editor component in a form through an ASP.NET MVC Editor template, its value will not be posted with the form. The reason for that is the inline mode that renders a DOM element, which is not a form field. Therefore, the value is not submitted with the form. To handle this scenario, customize the Editor template by adding a hidden input and update it when the content of the Editor changes.

Razor
    @model string

    @(Html.Kendo().EditorFor(model => model)
        .Name(Html.NameFor(model => model) + "_Editor")
        .Tag("div")
        .Tools(tools => tools.Clear().Bold().Italic().Underline())
        .Events(events => events.Change(@"function (ev){
            var hiddenInput =  $('#" + Html.NameFor(model => model) + @"');
            hiddenInput.val(ev.sender.value());
            hiddenInput.change();
        }"))
    )

    @Html.HiddenFor(model => model)

More ASP.NET MVC Editor Resources

See Also