ME-MarvinE / XCalendar

A plugin for .NET providing an API for representing a calendar along with fully customisable calendar controls for Xamarin Forms and .NET MAUI
MIT License
300 stars 36 forks source link

Type "xc:CalendarView" was not found #138

Closed Dan-WG closed 1 year ago

Dan-WG commented 1 year ago

Describe the bug I've added the package, in the viewmodel everthing is fine, but when I go to the xaml file, it tells me that the type xc:CalendarView could not be found. I've added "xmlns:xc="clr-namespace:XCalendar.Maui.Views;assembly=XCalendar.Maui"" but the error remains. Expected behavior Can use xc:CalendarView normally

Steps to reproduce OR link to code Downloaded packave via "Manage NuGet packages for solution Searched for "XCalendar.Maui" Version 4.4.2 was installed Added using XCalendar.Core.Models; and public Calendar MyCalendar { get; set; } = new Calendar(); to viewmodel along with NavigateCalendar functions. Now go to xaml file, add xmlns:xc="clr-namespace:XCalendar.Maui.Views;assembly=XCalendar.Maui and use xc:CalendarView to create a calendar.

Dan-WG commented 1 year ago

After deleting, clearing nu get packages cache and installing again seems to work, but Visual studio points out that as an error. Definetly a Visual's studio bug

ME-MarvinE commented 1 year ago

In case it happens again, usually a clean and rebuild will fix such "Not found" errors.

If it doesn't fix it, I try restarting Visual Studio, then I try restarting my machine, then I try the solution you had.