Without any reason, an error appeared in my views today :
CS0234 The type or namespace name 'Models' does not exist in the namespace 'Website' (are you missing an assembly reference?)
And the error is underlined at this line in my view :
@model Website.Models.EventIntro // Models is in red
I can't find the problem behind that error, any help would be welcome!
My Environment: VS 2017 , MVC 5.2.3.0
What i have tried so far :
-Switching to 3.0.0.0 in <add key="webpages:Version" value="3.0.0.0" />
-Cleaning ASP.NET temp files
EDIT: my model code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace Website.Models
{
public class EventIntro
{
public EventIntro() { }
public HtmlString Heading { get; set; }
public HtmlString Intro { get; set; }
public HtmlString Body { get; set; }
public HtmlString EventImage { get; set; }
public HtmlString Highlights { get; set; }
public HtmlString StartDate { get; set; }
public HtmlString Duration { get; set; }
public HtmlString Difficulty { get; set; }
}
}