Hi,
I have kendo grid read parameterized method, which search employees. When I as search string with "#" than it does not search. When I debug the code and check searchName value in controller, it was empty. I also checked Json request using IE developer tool, it also remove # values from query string.
I have pasted my code below. Please guide me.
1. Controller Read Method
2. Kendo Grid
I have kendo grid read parameterized method, which search employees. When I as search string with "#" than it does not search. When I debug the code and check searchName value in controller, it was empty. I also checked Json request using IE developer tool, it also remove # values from query string.
I have pasted my code below. Please guide me.
1. Controller Read Method
01.[HttpPost]02.public ActionResult ReadEmployee([DataSourceRequest] DataSourceRequest command,string searchName){03.var empList = GetEmployeeListByFirstAndLastName(searchName)04.var result = new DataSourceResult05. {06. Data = empList .FirstName,07. Total = empList .LastName08. };09.return Json(result,JsonRequestBehavior.AllowGet);@(Html.Kendo().Grid<EmployeeModel>() .Name("Grid") .DataSource(dataSource => dataSource .Ajax() .PageSize(20) .Read(read => read.Action("ReadEmployee", "Home", "#")) ) .Columns(columns => { columns.FirstName }) .Sortable() .Scrollable(scrollable => scrollable.Height("auto")) .Resizable(resizing => resizing.Columns(true)) .Pageable(pager => { pager.Refresh(true); pager.Numeric(true); }))