Search code examples
telerikformatkendo-gridtelerik-griddatagridviewcolumn

Format Data in Kendo Grid Column


Working with the kendo grid I just came accross a problem. I am populating the kendo grid with dynamic data and dynamic columns (column count and column names change) and thus I am not able to define anything for the column properties at the creation point. The code for the kendogrid creation looks like that:

enter image description here

I am working with ExpandoObject.

Everything works fine until there is a value which is loaded from the data which can't be shown.

This is the error: enter image description here

I think the problem is, that there is a link and it looks like that:

enter image description here

How can I format the columns to accept html? Do I have to loop afterwards and set some properties for the columns? How can I access the columns and set the attributes (which?). Or can we set something in the creation code?

Any help appreciated.

P.S. I am sorry for uploading screens and not text but I was not able to copy paste the stuff from the environment I am working at nor do I have any possibilities to transfer data. I was just able to take screenshots.


Solution

  • The problem was, that the column-titles contained non-alphanummeric characters and these are not allowed in the title. Whitespace is not allowed too. To fix my problem I looped through all the title values beforehand and removed the forbidden characters. Now it works but the question is still not resolved on how one could change this weird behaviour.