PDA

View Full Version : [CLOSED] [Razor] GridPanel ColumnModel Commands



Timothy
May 09, 2012, 8:51 PM
Hello,

The following example doesn't work? The commands is expecting type "GridCommandBase".



@(Html.X().GridPanel()
....
.ColumnModel(models =>
{
models.Add(Html.X().CommandColumn()
.Commands(commands =>
{
commands.Add(new ImageCommand());
} )
.Width(100)
);
} )
)


Any suggestions?

Cheers,
Timothy

Daniil
May 09, 2012, 10:39 PM
Hi,

Please use ImageCommandColumn for ImageCommands instead of CommandColumn.

By the way, a good point to use ImageCommands. It's much better in the performance (speed) aspect.