This is a migrated thread and some comments may be shown as answers.

2016.2.504 Error Kendo.Mvc.resources not found Adding Kendo.MVC to ASP.net core web application

1 Answer 333 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Oli
Top achievements
Rank 1
Oli asked on 10 May 2016, 05:59 PM

I'm getting a file not found (stack trace below) for Kendo.Mvc.resources while trying to add 2016.2.504 to an MVC6 project.

I installed the Kendo.MVC nuget package from the private feed 

     -- https://nuget.telerik.com/nuget

I also installed the bower package from 

    -- "kendo-ui": "https://bower.telerik.com/bower-kendo-ui.git#~2016.2.504"

 

I also added all the manual steps from http://docs.telerik.com/kendo-ui/aspnet-mvc/mvc-6/getting-started

 

Microsoft.AspNet.Server.Kestrel: Error: An unhandled exception was thrown by the application.
System.IO.FileNotFoundException: Could not find file 'Kendo.Mvc.resources'.
   at System.Reflection.RuntimeAssembly.InternalGetSatelliteAssembly(String name, CultureInfo culture, Version version, Boolean throwOnFileNotFound, StackCrawlMark& stackMark)
   at System.Resources.ManifestBasedResourceGroveler.GetSatelliteAssembly(CultureInfo lookForCulture, StackCrawlMark& stackMark)
   at System.Resources.ManifestBasedResourceGroveler.GrovelForResourceSet(CultureInfo culture, Dictionary`2 localResourceSets, Boolean tryParents, Boolean createIfNotExists, StackCrawlMark& stackMark)
   at System.Resources.ResourceManager.InternalGetResourceSet(CultureInfo requestedCulture, Boolean createIfNotExists, Boolean tryParents, StackCrawlMark& stackMark)
   at System.Resources.ResourceManager.InternalGetResourceSet(CultureInfo culture, Boolean createIfNotExists, Boolean tryParents)
   at System.Resources.ResourceManager.GetString(String name, CultureInfo culture)
   at Kendo.Mvc.Resources.Exceptions.get_Rtl()
   at Kendo.Mvc.UI.WidgetBase.VerifySettings()
   at Kendo.Mvc.UI.DatePicker.VerifySettings()
   at Kendo.Mvc.UI.WidgetBase.WriteHtml(TextWriter writer)
   at Kendo.Mvc.UI.DatePicker.WriteHtml(TextWriter writer)
   at Kendo.Mvc.UI.WidgetBase.RenderHtml(TextWriter writer)
   at Kendo.Mvc.UI.WidgetBase.ToHtmlString()
   at Kendo.Mvc.UI.Fluent.DeferredWidgetBuilder`1.ToHtmlString()
   at Kendo.Mvc.UI.Fluent.DeferredWidgetBuilder`1.WriteTo(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.ViewFeatures.StringCollectionTextWriter.StringCollectionTextWriterContent.WriteTo(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.ViewFeatures.StringCollectionTextWriter.CopyTo(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.ViewFeatures.StringCollectionTextWriter.CopyToAsync(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.Razor.RazorTextWriter.CopyToAsync(TextWriter writer)
   at Microsoft.AspNet.Mvc.Razor.HelperResult.WriteTo(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.ViewFeatures.StringCollectionTextWriter.StringCollectionTextWriterContent.WriteTo(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.ViewFeatures.StringCollectionTextWriter.CopyTo(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.ViewFeatures.StringCollectionTextWriter.CopyToAsync(TextWriter writer, IHtmlEncoder encoder)
   at Microsoft.AspNet.Mvc.Razor.RazorTextWriter.CopyToAsync(TextWriter writer)
   at Microsoft.AspNet.Mvc.Razor.RazorView.<RenderLayoutAsync>d__20.MoveNext()

1 Answer, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 12 May 2016, 02:21 PM
Hello,

Thanks for the detailed bug report.

From the stack trace I can see that the DatePicker widget is trying to read the exception message for an "Rtl" exception and fails.
We'll investigate why the exception message is not available in the resource file.

This is the message that should be displayed:
    The "{0}" class is no longer supported. To enable RTL support you must include telerik.rtl.css and apply the "t-rtl" class to a parent HTML element or the <body>.

And this is the code throwing it:
        public virtual void VerifySettings()
        {
            if (!Name.Contains("<#=") && Name.IndexOf(" ") != -1)
            {
                throw new InvalidOperationException(Resources.Exceptions.NameCannotContainSpaces);
            }

            ((IHtmlAttributesContainer) this).ThrowIfClassIsPresent("k-" + GetType().Name.ToLowerInvariant() + "-rtl", Resources.Exceptions.Rtl);
        }


Try removing the k-datepicker-rtl class, if it is set via HtmlAttributes.

I hope this helps.

Regards,
T. Tsonev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
General Discussions
Asked by
Oli
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Share this question
or