Friday, July 8, 2011

Error: List<> does not contain a definition for 'Sum'

Error 'System.Collections.Generic.List<>' does not contain a definition for 'Sum' and no extension method 'Sum' accepting a first argument of type 'System.Collections.Generic.List<>' could be found (are you missing a using directive or an assembly reference?)

This error cropped up when converting a solution from .NET 2 to .NET 4.  Just add

using System.Linq;





1 comment:

  1. Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging. If anyone wants to become a .Net developer learn from Dot Net Training in Chennai. or learn thru ASP.NET Essential Training Online . Nowadays Dot Net has tons of job opportunities on various vertical industry.
    or Javascript Training in Chennai. Nowadays JavaScript has tons of job opportunities on various vertical industry.

    ReplyDelete