Hi,
I have a couple of classes all of them deriving from IQueryResult. I need each of those classes to be iterable in foreach loop. Unfortunately foreach loop cannot see GetEnumerator method. I've managed to use it in foreach using dynamic keyword available in .NET 4.0 but then IQueryResult need not to derive from IEnumerable.
public interface IQueryResult : IEnumerable<IQueryResult>
{
}
How would you do that in a more elegant way?
Kind Regards PK