0
votes

Kendo grid datasource is not passing values "&" from view to controller in MVC

For instance from the below code if testIdVal value is "Interface Class & Function" . Only "Interface Class" are being passed to the controller .

.DataSource(Function(d) d.Ajax() _
                                    .Read(Function(read) read.Action("GetResourcesForRolesForRootDomain", "Inquiry", New With {.testId= "#=testIdVal#"}).Type(HttpVerbs.Post).Data("additionalData"))) _
1
Two ideas on that one: Try to add encodeURIComponent around testIdVal: "#=encodeURIComponent(testIdVal)#"or add testIdVal in additinaldata. By the way, there is a typo in additinaldata ;)Carsten Franke
Thanks a lot Carsten , "#=encodeURIComponent(testIdVal)#" worked , Indeed additinaldata was a typo :) . You can put this in the answer list so that I will accept this as correct one .karthik kasubha

1 Answers

1
votes

Two ideas on that one: Try to add encodeURIComponent around testIdVal: "#=encodeURIComponent(testIdVal)#" or add testIdVal in additinaldata. By the way, there is a typo in additinaldata. ;)