DayPilot Pro for ASP.NET MVC is compatible with MVC 3 and it supports the Razor view engine.
See also:
Here is an example for DayPilot Calendar:
1. Add a reference to DayPilot.Web.Mvc.dll to the project or add it to the Bin directory of the web application.
2. In order to enable the HTML helpers, add the following DayPilot.Web.Mvc to the namespaces in Views/web.config:
<configuration> <system.web.webPages.razor> <pages pageBaseType="System.Web.Mvc.WebViewPage"> <namespaces> ... <add namespace="DayPilot.Web.Mvc" /> ... </namespaces> </pages> </system.web.webPages.razor> </configuration>
3. Now you can use the DayPilot helpers in the Razor views (Index.cshtml).
@using DayPilot.Web.Mvc.Events.Calendar; @using DayPilot.Web.Mvc.Enums.Calendar; @{ ViewBag.Title = "Index"; Layout = "~/Views/Shared/_Layout.cshtml"; } <h2>Index</h2> @Html.DayPilotCalendar("dpc", new DayPilotCalendarConfig { BackendUrl = Url.Content("~/Backend/Calendar"), EventResizeHandling = EventResizeHandlingType.CallBack, EventMoveHandling = EventMoveHandlingType.CallBack, TimeRangeSelectedHandling = TimeRangeSelectedHandlingType.CallBack, ViewType = DayPilot.Web.Mvc.Enums.Calendar.ViewType.Week, Days = 7, StartDate = DayPilot.Web.Mvc.Utils.Week.FirstDayOfWeek(), BusinessBeginsHour = 9, BusinessEndsHour = 18, CssClassPrefix = "calendar_silver_", EventArrangement = ArrangementType.Full })