On Aug 28, 4:20 pm, Juan Puebla <JuanPue...@discussions.microsoft.com>
wrote:
Hi,
I'm trying to use Linq in a webservice that returns a data from a query. As
the data return from Linq to Sql is IEnumerable<Tand it's not possible to
easily get a Dataset, Which is the best format to return data?
Thanks
Assuming T is a value that can be serialized and returned from the web
service, I would recommend that you return T[]. Use Generics List to
turn the value into a list and then return the values as an array.
T[] GetValues()
{
return new List<T>( .. IEnumerable<T).ToArray();
}
Ron