Hi Steffen,
Thanks for using Syncfusion products.
We suggest you to handle QueryCellInfo to achieve your
requirement. Please refer to the code snippet below to achieve this.
[ASPX]
@( Html.Syncfusion().Grid<Sample.Models.JSONOrder>('SampleGrid')
.Datasource(Model)
.Caption('Orders')
.QueryCellInfo(
cell => Html.RenderAction('onQueryCellAction', 'Home', new { args = cell })
)
)
[Controller]
[AcceptVerbs(HttpVerbs.Post)]
public ActionResult Index(PagingParams args)
{
IEnumerable data = GridOrders;
var engine = data.GridActions<JSONOrder>() as GridHtmlActionResult<JSONOrder>;
engine.GridModel.QueryCellInfo = onQueryCellAction;
return engine;
}
public void onQueryCellAction(GridTableCell<JSONOrder> args)
{
if (args.TableCellType == GridTableCellType.RecordFieldCell || args.TableCellType == GridTableCellType.AlternateRecordFieldCell)
{
if (args.Column.MappingName == 'EmployeeID')
{
args.Text = '<a class='TemplateCell' rel='nofollow' href='Home/Load?id='+args.Data.OrderID+''>' + args.Data.EmployeeID + '</a>';
}
}
}
Please refer to the below link to download the
sample application.
Sample.zip
Please let me know if you have any concern.
Regards,
Ranjithkumar