Friday, 12 February 2016

MVC - Fix error - JavaScript runtime error: Object doesn't support property or method

Watch this example on YouTube:



Replace

        @Scripts.Render("~/bundles/jqueryui")
        @Styles.Render("~/Content/themes/base/css", "~/Content/css")
        @Scripts.Render("~/Scripts/DatePicker.js")   
        @Scripts.Render("~/bundles/jquery")
        @RenderSection("scripts", required: false)
    </body>

with
@Scripts.Render("~/bundles/jquery")
        @Scripts.Render("~/bundles/jqueryui")
        @Styles.Render("~/Content/themes/base/css", "~/Content/css")
        @Scripts.Render("~/Scripts/DatePicker.js")   
      
        @RenderSection("scripts", required: false)
    </body>

order matters

No comments:

Post a Comment