I've got the following code which doesn't seem to render correctly, it moves the fields outside of the form, so the form is an empty tag. I tried adding .Render() to both tabstrip and window at different times and gained a .NET error
"CS1502: The best overloaded method match for 'System.Web.WebPages.WebPageExecutingBase.Write(System.Web.WebPages.HelperResult)' has some invalid arguments "
@(Html.Kendo().TabStrip() .Name("tabstrip") .Items(tabstrip => {@*More tabs*@ tabstrip.Add().Text("Create New Task") .Content( @<text> @using (Ajax.BeginForm(null, null, new AjaxOptions { Url = Url.Action("UserAddNewTask", "ProjectApi", new { area = "API" }), OnSuccess = "CloseAndRefreshTaskGrid()" }, new { @id = "newTaskForm" })) { @Html.Hidden("Id") <div class="container-fluid"> @*More fields*@ <div class="row top10"> @Html.Label("Task Name", new { }) @Html.Kendo().TextBoxFor(model => model.Name) @Html.ValidationMessageFor(model => model.Name, "", new { @class = "text-danger" }) </div> <div class="row top10"> <button class="btn btn-success" id="btnNewTaskSubmit" type="submit">Submit</button> </div> </div> } </text>); }))
@(Html.Kendo().TabStrip() .Name("tabstrip") .Items(tabstrip => { tabstrip.Add().Text("Create New Task") .Content( @<text> @using (Ajax.BeginForm(null, null, new AjaxOptions { Url = Url.Action("UserAddNewTask", "ProjectApi", new { area = "API" }), OnSuccess = "CloseAndRefreshTaskGrid()" }, new { @id = "newTaskForm" })) { @Html.Hidden("Id") <div class="container-fluid"> @*More fields*@ <div class="row top10"> @Html.Label("Task Name", new { }) @Html.Kendo().TextBoxFor(model => model.Name) @Html.ValidationMessageFor(model => model.Name, "", new { @class = "text-danger" }) </div> <div class="row top10"> <button class="btn btn-success" id="btnNewTaskSubmit" type="submit">Submit</button> </div> </div> } </text>); }))​
@(Html.Kendo().Window() .Name("editTaskModal") .Modal(true) .Draggable() .Actions(a => a.Pin().Maximize().Minimize().Close()) .Title("Edit Task") .Width(800) .Visible(false) .Position(p => p.Top(150)) //.Content(@Partial/_TimesheetNewTask") .Content(@<text>@Html.Partial("Partial/_TimesheetNewTask")</text>))​