When I run the Update-Database
command in the Package Manager Console, I get the following error:
Value can not be null. Parameter name: entitySet
I have only one model in the project for now
public class Project
{
[Key]
public Guid ProjectId { get; set; }
public String Title { get; set; }
public String Content { get; set; }
public HttpPostedFileBase Image { get; set; }
public String Author { get; set; }
public String FileWay { get; set; }
[Required]
public DateTime DateProject { get; set; }
public DateTime? DateUpdate { get; set; }
public DateTime DateAudience { get; set; }
}
And my class DBContext
:
public class DialogoContext : IdentityDbContext<UserClient,Group , Guid, UserLogin, UserGroup, UserIdentity>
{
public DialogoContext()
: base("DialogoContext")
{
}
public static DialogoContext Create()
{
return new DialogoContext();
}
public DbSet<Project> Projects { get; set; }
}
I did not identify the reason for this error.
What causes this error? How can I resolve it?