Grid server template

2 posts, 0 answers
  1. Chris Williams
    Chris Williams avatar
    63 posts
    Member since:
    Oct 2004

    Posted 16 Aug 2012 Link to this post

    Is this form of server template creation supported in Kendo/MVC?

    .Template(t =>
        {
           @<text>
           This is my custom template
           </text>
        }                                                       
     )

    I've seen server templates created like this but not like the above.
  2. Chris Williams
    Chris Williams avatar
    63 posts
    Member since:
    Oct 2004

    Posted 16 Aug 2012 Link to this post

    OK, this seems to work.

    .Template(t =>
                  {
                      IDictionary<String, Object> values = (IDictionary<String, Object>) t;
                      object value;
                      values.TryGetValue(string.Concat(series.Source, "-", series.Field), out value);
                      return Html.WriteValue(values, value, series);
                  }                                                                                              
    )
  3. UI for ASP.NET MVC is VS 2017 Ready
Back to Top