This is a migrated thread and some comments may be shown as answers.

[Solved] two radgrids dataBinding .Select

0 Answers 12 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
diego
Top achievements
Rank 1
diego asked on 10 Aug 2011, 08:45 PM

I have the following two radgrids (I have omitted .Insert - .Update - .Delete))

@(Html.Telerik().Grid<

ActivoViewModel.ActivoVM>()

 .Name("Grid")

 .ToolBar(commands => commands.Insert())

.DataKeys(keys => keys.Add(c => c.Id))

.DataBinding(dataBinding => dataBinding.Ajax()

.Select("_SelectDatoOperativo", "Activo")

 .Columns(columns =>

 

{

columns.Bound(o => o.IdTipoDato).Width(200);

columns.Bound(o => o.Descripcion);

columns.Bound(o => o.Valordato);

columns.Command(commands => { commands.Edit(); commands.Delete(); }).Width(200);

})



@(Html.Telerik().Grid<

ActivoViewModel.ActivoVM>()

 .Name( "Grid")

 .ToolBar(commands => commands.Insert())

.DataKeys(keys => keys.Add(c => c.Id))

.DataBinding(dataBinding => dataBinding.Ajax()

.Select("_SelectComponente", "Activo")

 .Columns(columns =>

 

{

columns.Bound(o => o.IdTipoComponente).Width(230);

columns.Bound(o => o.Noserie);

columns.Bound(o => o.Versionfirmware);

columns.Command(commands => { commands.Edit(); commands.Delete(); }).Width(200);

})

)

When I use the actionresult with the first radgrid, the secondg radgrid .Select is never called

 

[GridAction]

public ActionResult _SelectDatoOperativo()

 {

 return View(new GridModel(_modelo.VMActivo.DatoOperativo));

 }

[GridAction]

 public ActionResult _SelectComponente()

 {

 return View(new GridModel(_modelo.VMActivo.Componente));

 }

How can I do to call the second action result??

Thanks in advance

Tags
General Discussions
Asked by
diego
Top achievements
Rank 1
Share this question
or