如何使LINQ查询操作符,如where,join,groupby访问NameValueCollection
?
我尝试了以下几种方法:
private NameValueCollection RequestFields()
{
NameValueCollection nvc = new NameValueCollection()
{
{"emailOption: blah Blah", "true"},
{"emailOption: blah Blah2", "false"},
{"nothing", "false"},
{"nothinger", "true"}
};
return nvc;
}
public void GetSelectedEmail()
{
NameValueCollection nvc = RequestFields();
IQueryable queryable = nvc.AsQueryable();
}
但是ArgumentException告诉我的来源不是IEnumerable<>。
https://stackoverflow.com/questions/391023
复制相似问题