October 16, 2014

Error: Entity framework "Cannot convert from 'System.Data.Objects.ObjectParameter' to 'System.Data.Entity.Core.Objects.ObjectParameter"

Entity Framework ERROR: Cannot convert from 'System.Data.Objects.ObjectParameter' to 'System.Data.Entity.Core.Objects.ObjectParameter[]' entity framework 6

This is one of most frequent compile time error you may face in Entity Framework. This is because either of:

1. Version conflict or
2. Namespace used.

By default, while compiling project, framework includes namespace using System.Data.Objects;


To fix this issue:

If version conflicts, install package for respective version of EF.

If version is same, change the above namespace to System.Data.Entity.Core.Objects