We are trying to use the fluent interface to generate a Linq query that applies a where clause:
em.ExecuteQueryAsync<Principal>(em.Principals.Where(p => p.DisplayName == "ahopper"), this.QueryExecuted, null);
However, when the callback is invoked, it has an error:
“Type 'System.Reflection.RuntimeMethodInfo' cannot be serialized. Consider marking it with the DataContractAttribute attribute, and marking all of its members you want serialized with the DataMemberAttribute attribute. Alternatively, you can ensure that the type is public and has a parameterless constructor - all public members of the type will then be serialized, and no attributes will be required.”
Are we simply using the API incorrectly?
Many thanks!
Andy Hopper
Enterprise Architect, Wintellect