"entry point was not found"--manually adding MVC to legacy webforms

11 posts, 1 answers
  1. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 02 Sep 2015 Link to this post

    I am adding MVC & Telerik Kendo to legacy webforms application.

    I have only just added MVC 5 itself to the project using an MVC area. (see http://www.davepaquette.com/archive/2013/12/30/so-you-inherited-an-asp-net-web-forms-application.aspx).

    To add Telerik MVC, I am following the steps here: http://docs.telerik.com/kendo-ui/aspnet-mvc/asp-net-mvc-5

     When I get to the step adding @(Html.Kendo().DatePicker().Name("datepicker")) to a "hello world" mvc, and try to access it, I get a "System.EntryPointNotFoundException".

     Any ideas what could be wrong?

     Additional info:  

     I made the web.config changes to (and only to) the web.config file in the MVC area.

     The "~/Content/kendo/..." and "~/Scripts/kendo/..." are in their standard places, not in the MVC area.  Not sure if this matters, but no errors appear to be generated by the telerik bundles in BundleConfig.vb.

    Googling I have found mentions of <bindingredirects> in the web.config, but the Telerik instructions I am following to not mention this possibility.

  2. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 02 Sep 2015 in reply to Scott Link to this post

    Here is the stack trace:

     [EntryPointNotFoundException: Entry point was not found.]

    System.Web.Mvc.IViewDataContainer.get_ViewData() +0

    Kendo.Mvc.UI.Fluent.WidgetFactory.DatePicker() +44

    ASP._Page_Areas_MVC_Views_yowhatsup_Index_vbhtml.Execute() in D:\repos\Gone Gaia\MvcTest-Scott-BB\Trac\Trac.Application\Areas\MVC\Views\yowhatsup\Index.vbhtml:8

    System.Web.WebPages.WebPageBase.ExecutePageHierarchy() +197

    System.Web.Mvc.WebViewPage.ExecutePageHierarchy() +105

    System.Web.WebPages.StartPage.RunPage() +17

    System.Web.WebPages.StartPage.ExecutePageHierarchy() +64

    System.Web.WebPages.WebPageBase.ExecutePageHierarchy(WebPageContext pageContext, TextWriter writer, WebPageRenderingBase startPage) +78

    System.Web.Mvc.RazorView.RenderView(ViewContext viewContext, TextWriter writer, Object instance) +235

    System.Web.Mvc.BuildManagerCompiledView.Render(ViewContext viewContext, TextWriter writer) +107

    System.Web.Mvc.ViewResultBase.ExecuteResult(ControllerContext context) +291

    System.Web.Mvc.ControllerActionInvoker.InvokeActionResult(ControllerContext controllerContext, ActionResult actionResult) +13

    System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +56

    System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +420

    System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters(ControllerContext controllerContext, IList`1 filters, ActionResult actionResult) +52

    System.Web.Mvc.Async.<>c__DisplayClass2b.<BeginInvokeAction>b__1c() +173

    System.Web.Mvc.Async.<>c__DisplayClass21.<BeginInvokeAction>b__1e(IAsyncResult asyncResult) +100

    System.Web.Mvc.Async.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult) +10

    System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49

    System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeAction(IAsyncResult asyncResult) +27

    System.Web.Mvc.Controller.<BeginExecuteCore>b__1d(IAsyncResult asyncResult, ExecuteCoreState innerState) +13

    System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +29

    System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49

    System.Web.Mvc.Controller.EndExecuteCore(IAsyncResult asyncResult) +36

    System.Web.Mvc.Controller.<BeginExecute>b__15(IAsyncResult asyncResult, Controller controller) +12

    System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +22 System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49

    System.Web.Mvc.Controller.EndExecute(IAsyncResult asyncResult) +26

    System.Web.Mvc.Controller.System.Web.Mvc.Async.IAsyncController.EndExecute(IAsyncResult asyncResult) +10

    System.Web.Mvc.MvcHandler.<BeginProcessRequest>b__5(IAsyncResult asyncResult, ProcessRequestState innerState) +21

    System.Web.Mvc.Async.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) +29

    System.Web.Mvc.Async.WrappedAsyncResultBase`1.End() +49

    System.Web.Mvc.MvcHandler.EndProcessRequest(IAsyncResult asyncResult) +28

    System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) +9

    System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +9711525

    System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +155

  3. UI for ASP.NET MVC is VS 2017 Ready
  4. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 02 Sep 2015 in reply to Scott Link to this post

    Further info:

    I am using MVC 5.2.3 specifically.

     I have already read this:  http://www.finutia.com/blogutia/entry-point-was-not-found

    I have tried adding this to the web.config:

       <runtime>
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
          <dependentAssembly>
            <assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
            <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
          </dependentAssembly>
          <dependentAssembly>
            <assemblyIdentity name="System.Web.WebPages.Razor" publicKeyToken="31bf3856ad364e35" />
            <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
          </dependentAssembly>
          <dependentAssembly>
            <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31BF3856AD364E35" />
            <bindingRedirect oldVersion="1.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
          </dependentAssembly>
        </assemblyBinding>
      </runtime>

     

  5. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 02 Sep 2015 Link to this post

    For what it is worth, here is the complete web.config in the MVC area:

     <?xml version="1.0"?>

    <configuration>
      <configSections>
        <sectionGroup name="system.web.webPages.razor" type="System.Web.WebPages.Razor.Configuration.RazorWebSectionGroup, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
          <section name="host" type="System.Web.WebPages.Razor.Configuration.HostSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" />
          <section name="pages" type="System.Web.WebPages.Razor.Configuration.RazorPagesSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" />
        </sectionGroup>
      </configSections>

      <system.web.webPages.razor>
        <host factoryType="System.Web.Mvc.MvcWebRazorHostFactory, System.Web.Mvc, Version=5.2.3.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
        <pages pageBaseType="System.Web.Mvc.WebViewPage">
          <namespaces>
            <add namespace="System.Web.Mvc" />
            <add namespace="System.Web.Mvc.Ajax" />
            <add namespace="System.Web.Mvc.Html" />
            <add namespace="System.Web.Routing" />
            <add namespace="System.Web.Optimization" />
            <add namespace="Trac.Application" />
            <add namespace="Kendo.Mvc.UI" />
          </namespaces>
        </pages>
      </system.web.webPages.razor>

      <appSettings>
        <add key="webpages:Enabled" value="false" />
      </appSettings>

      <system.webServer>
        <handlers>
          <remove name="BlockViewHandler"/>
          <add name="BlockViewHandler" path="*" verb="*" preCondition="integratedMode" type="System.Web.HttpNotFoundHandler" />
        </handlers>
      </system.webServer>

      <runtime>
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
          <dependentAssembly>
            <assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
            <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
          </dependentAssembly>
          <dependentAssembly>
            <assemblyIdentity name="System.Web.WebPages.Razor" publicKeyToken="31bf3856ad364e35" />
            <bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
          </dependentAssembly>
          <dependentAssembly>
            <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31BF3856AD364E35" />
            <bindingRedirect oldVersion="1.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
          </dependentAssembly>
        </assemblyBinding>
      </runtime>


    </configuration>

  6. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 02 Sep 2015 Link to this post

    There seems to be a thread about the same problem, that has not gotten far:

     

    http://www.telerik.com/forums/compile-kendo-mvc-against-mvc-5-2-3#LlxtAV1tmkespt3RBEPseA​

  7. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 03 Sep 2015 Link to this post

    Also possibly useful is the version information provided with the error:

     Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.6.81.0              

    Note that 4.0.30319 is the "runtime version" of my System.web.mvc, but it's "version" is 5.2.3.  Version numbers always make so much sense, don't they?  I am pretty sure it is the 5.2.3 that should be used in the bindingredirects, if such are even needed.

  8. Kiril Nikolov
    Admin
    Kiril Nikolov avatar
    2564 posts

    Posted 07 Sep 2015 Link to this post

    Hello Scott,

     

    Would it be possible to share the project with us, so we can investigate the runnable sample and see what happens? We need this because from the provided information we are not able to determine what is causing the problem and suggest a possible solution.

     

    Thanks for the cooperation.

     

    Regards,
    Kiril Nikolov
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  9. Kiril Nikolov
    Admin
    Kiril Nikolov avatar
    2564 posts

    Posted 07 Sep 2015 Link to this post

    Hello Scott,

     

    I have a question that might be related to the problem - are you sure that the Kendo UI MVC assembly that you reference in your project is for the correct MVC version that you are using?

     

    Regards,
    Kiril Nikolov
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  10. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 22 Sep 2015 in reply to Kiril Nikolov Link to this post

    Hi,

    Haven't been able to follow up on this for a while.

     Where exactly would I check for the version mismatch?  Thanks!

     

  11. Scott
    Scott avatar
    28 posts
    Member since:
    May 2015

    Posted 22 Sep 2015 Link to this post

    Here are I think there relevant version #s:

     Kendo.Mvc:  2015.2.805.545

    System.Web.Mvc:  5.2.3

    and we also have (used by legacy code, unrelated to our efforts to convert to Mvc&Kendo in general):

    Terlerik.Web.UI 2010.3.1215.40   <--- could this be creating a conflict of some kind?

  12. Answer
    Atanas Korchev
    Admin
    Atanas Korchev avatar
    8462 posts

    Posted 25 Sep 2015 Link to this post

    Hi Scott,

    We tried to reproduce the problem to no avail. Find attached our test project which uses  Kendo.Mvc:  2015.2.805.545 and System.Web.Mvc:  5.2.3 and works as expected.

    You can try removing Telerik.Web.UI temporarily to see if it makes a difference. The stacktrace of the exception should show its cause. 

    Regards,
    Atanas Korchev
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top
UI for ASP.NET MVC is VS 2017 Ready