Mono Develop 2.4.1 + linq error.
- by Nev_Rahd
I just started to learn Mono Develop
Installed Mono Develop 2.4.1 and trial version of Mono Touch.
my Code:
using System;
using System.Xml.Linq;
using System.Collections.Generic;
namespace RSSReader
{
public static class RSSRepository
{
public static IList<FeedItem> GetFeeds(string url)
{
XDocument rssFeed = XDocument.Load(url);
Console.Write(rssFeed.ToString());
var feeds = new List<FeedItem>();
try {
var query = from item in rssFeed.Descendants("item")
select new FeedItem
{
Title = item.Element("title").Value,
Published = DateTime.Parse(item.Element("pubDate").Value),
Url = item.Element("link").Value
};
feeds = query.ToList();
}
catch (Exception ex){
Console.WriteLine(ex.Message);
}
return feeds;
}
}
}
This is throwing an error: An implementation of 'select' query expression pattern could not be found. Are you missing 'System.linq' using directive or 'System.Core.dll' assembly reference?
I got both references to System.Xml.Linq and System.Core
What am i missing ?