Quantcast
Channel: Security
Viewing all articles
Browse latest Browse all 4737

Method not found FirstOrDefaultAsync

$
0
0

Im not sure if it is related but this is what i discovered after installing TS1.4 for VS2013

After starting my project i got the following mesage:

Method not found: 'System.Threading.Tasks.Task`1<!!0> System.Data.Entity.QueryableExtensions.FirstOrDefaultAsync(System.Linq.IQueryable`1<!!0>, System.Linq.Expressions.Expression`1<System.Func`2<!!0,Boolean>>)'.

in the following default part of my code

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.MissingMethodException: Method not found: 'System.Threading.Tasks.Task`1<!!0> System.Data.Entity.QueryableExtensions.FirstOrDefaultAsync(System.Linq.IQueryable`1<!!0>, System.Linq.Expressions.Expression`1<System.Func`2<!!0,Boolean>>)'.

Source File: c:\Projects\poco\R1\poco-orderapp\poco-orderapp.web\Controllers\AccountController.cs    Line: 48 

Does anyone know how to solve this. I already uninstalled TS1.4 ??

I'm using packages\Microsoft.AspNet.Identity.EntityFramework.2.2.1\lib\net45\Microsoft.AspNet.Identity.EntityFramework.dll

Target Framework is .Net Framework 4.5.1

Line 46:             if (ModelState.IsValid)
Line 47:             {Line 48:                 var user = await UserManager.FindAsync(model.UserName, model.Password);Line 49:                 if (user != null)
Line 50:                 {




Viewing all articles
Browse latest Browse all 4737

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>