This question is locked. New answers and comments are not allowed.
Hi. I have problem with Telerik Grid with 2 or more IntegerTextBox Templates when I use the edit mode (I use popup edit mode).
When the popup is showed, only the last IntegerTextBox show the correct value. The others IntegerTextBox show the "0" value.
Is similar to this error
My View Model is:
My Telerik grid is (I use T4MVC):
And my editor for "Double" are:
In the image 1, i show an example with 2 "double" template. In the image 2, i show an example with 3 "double" template.
Any solution? My telerik version is 2010.3.1129.235
Thanks.
When the popup is showed, only the last IntegerTextBox show the correct value. The others IntegerTextBox show the "0" value.
Is similar to this error
My View Model is:
public class ConditionedAlternativeViewModel { [ScaffoldColumn(false)] public int Id { get; set; } [Required(ErrorMessage = "Campo obligatorio")] [DisplayName("Descripción izquierda")] [DataType(DataType.Text)] public string DescripcionIzquierda { get; set; } [Required(ErrorMessage = "Campo obligatorio")] [DisplayName("Puntaje izquierda")] [DataType("Double")] [Range(0, int.MaxValue, ErrorMessage = "Ingrese un valor mayor o igual 0")] public double PuntajeIzquierda { get; set; } [Required(ErrorMessage = "Campo obligatorio")] [DisplayName("Descripción derecha")] [DataType(DataType.Text)] public string DescripcionDerecha { get; set; } [Required(ErrorMessage = "Campo obligatorio")] [DisplayName("Puntaje derecha")] [DataType("Double")] [Range(0, int.MaxValue, ErrorMessage = "Ingrese un valor mayor o igual 0")] public double PuntajeDerecha { get; set; } }My Telerik grid is (I use T4MVC):
<%= Html.Telerik().Grid<PHDWeb.ViewModels.ConditionedAlternativeViewModel>() .Name("ConditionedAlternativeGrid") .Localizable("es-ES") .DataKeys(keys => keys.Add(p => p.Id)) .ToolBar(commands => commands.Insert().ButtonType(GridButtonType.ImageAndText).ImageHtmlAttributes(new { style = "margin-left:0" })) .DataBinding(dataBinding => { dataBinding.Ajax() .Select(MVC.PortalSercotec.Alternative._SelectConditionedAlternative().GetRouteValueDictionary()) .Insert(MVC.PortalSercotec.Alternative._InsertConditionedAlternative().AddRouteValue("QuestionId", Url.RequestContext.RouteData.Values["id"]).GetRouteValueDictionary()) .Update(MVC.PortalSercotec.Alternative._UpdateConditionedAlternative().AddRouteValue("QuestionId", Url.RequestContext.RouteData.Values["id"]).GetRouteValueDictionary()) .Delete(MVC.PortalSercotec.Alternative._DeleteConditionedAlternative().AddRouteValue("QuestionId", Url.RequestContext.RouteData.Values["id"]).GetRouteValueDictionary()); }) .Columns(columns => { columns.Bound(p => p.DescripcionIzquierda).Title("Descripción izquierda"); columns.Bound(p => p.PuntajeIzquierda).Title("Puntaje izquierda"); columns.Bound(p => p.DescripcionDerecha).Title("Descripción derecha"); columns.Bound(p => p.PuntajeDerecha).Title("Puntaje derecha"); columns.Command(commands => { commands.Edit().ButtonType(GridButtonType.ImageAndText); commands.Delete().ButtonType(GridButtonType.ImageAndText); }).Width(250).Title("Acciones"); }) .Editable(editing => editing.Mode(GridEditMode.PopUp)) .Pageable()And my editor for "Double" are:
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<double>" %><%= Html.Telerik().IntegerTextBox() .Name(ViewData.TemplateInfo.GetFullHtmlFieldName(string.Empty)) .ButtonTitleUp("Incrementar valor") .ButtonTitleDown("Disminuir valor") .InputHtmlAttributes(new { style = "width:100%" }) .MinValue(0) .MaxValue(int.MaxValue) .Value(Convert.ToInt32(Model)) .InputHtmlAttributes(new { value = Convert.ToInt32(Model) })%>In the image 1, i show an example with 2 "double" template. In the image 2, i show an example with 3 "double" template.
Any solution? My telerik version is 2010.3.1129.235
Thanks.