Dictionary<String, List<String>> filters = new Dictionary<String, List<String>>();
它具有类似于
country = us
值
存在追加。直到现在我可以在不重复密钥的情况下添加它。现在重复键country
。它表明钥匙已经存在。
我想要的是如何在同一个键中添加多个值。我无法做到。请提出建议。
for (int i = 0; i < msgProperty.Value.Count; i++)
{
FilterValue.Add(msgProperty.Value[i].filterValue.Value);
filterColumn = msgProperty.Value[i].filterColumnName.Value;
filters.Add(filterColumn, FilterValue);
}
我想
国家=美国,英国
实现考虑使用'Lookup'代替'Dictionary' –
@与名单> W.B? –
'Lookup' –