@Tony, the Razor Where clause is different from the standard LINQ Where. In Razor it's really only meant to take strings. From what I understand, this is because dynamic objects are being used. Anyhow, here's an example of the correct way to use strings in the Where clause to filter your collection:
string value = "Some Value"; records = records.Where("property == @0", value);
Hopefully something like that will work better for you.
Spaces in Where() clause
I'm having an issue with a filtering function I have
If
I get back the records anticipated
Nothing, despite there being nodes that should be returned.
I'm getting the value (from a dropdown) by posting back a form
@Tony, the Razor Where clause is different from the standard LINQ Where. In Razor it's really only meant to take strings. From what I understand, this is because dynamic objects are being used. Anyhow, here's an example of the correct way to use strings in the Where clause to filter your collection:
Hopefully something like that will work better for you.
Cheers.
is working on a reply...