WidgetExtensions
Class
Extension methods for IWidget.
Definition
Namespace:Kendo.Mvc.Extensions
Assembly:Kendo.Mvc.dll
Syntax:
C#
public static class WidgetExtensions
Inheritance: objectWidgetExtensions
Inherited Members
Methods
Gets the formatted value for a widget from various sources (model state, ViewData, or the provided value) with custom formatting.
C#
public static string GetValue<T>(this IWidget instance, string name, T value, string format = "{0}")
The widget instance.
namestringThe name of the field to retrieve the value for.
valueTThe value to use if no other source provides a value.
formatstringThe format string to apply to the value (default is "{0}").
Returns:The formatted string value.
Gets the formatted value for a widget from various sources (model state, ViewData, or the provided value).