I have an .ascx view that I need to use the server and client checkbox templates. If I use the ClientTemplate by itself the example works. If I add or just try to use the server .Template or .HeaderTemplate, I get a syntax (unexpected token) issue. I used the exact syntax from the Telerik site example. If someone could get this working it would be much appreciated. Thx.
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<MultiSelectList>" %>
<%= Html.Telerik().Grid(Model)
.Name("Functions")
.Columns(columns =>
{
columns.Bound(o => o.Selected)
.HeaderTemplate(() =>
{
%> <input id="chkAll" type="checkbox" title="check all records" />
<%
})
.ClientTemplate("<input type='checkbox' name='checkedRecords' value='<#= Value #>' />")
.Template(o => {
%>
<input name="checkedRecords" type="checkbox" value="<%= o.Value %>"
<%
if (o.Selected) {%> checked="checked" <%} %> />
<%}).Title("").Width(36).HtmlAttributes(new {style = "text-align:center"});
columns.Bound(o => o.Text).Title("Document Functions");})
.Footer(false)
.DataBinding(binding => binding.Ajax().Select("GetFunctions", "Revision"))
.Scrollable(scrolling => scrolling.Height(50).Enabled(true))
%>