Alternative coding to a conditional var inferred-type query LINQ to XML?

Posted by Programmer's Goodies on September 30, 2011

This is a follow up on a related topic found here http://stackoverflow.com/questions/1987485/conditionally-assign-c-var-as-elegant-as-it-gets if I am doing the following: var query = (SearchString == "" ? ( from MEDIA in xdoc.Descendants("MEDIA") select new { PLAY = MEDIA.Element("PLAY").Value, PIC

... [read more]

Rating

not rated

Reviews

There are currently no comments or reviews.

Submit a review:

Login required.