NameValueCollection
すべての値を単一の文字列としてキーにする
方法、次の方法を使用して取得しています。
public static string GetAllReasons(NameValueCollection valueCollection)
{
string _allValues = string.Empty;
foreach (var key in valueCollection.AllKeys)
_allValues += valueCollection.GetValues(key)[0] + System.Environment.NewLine;
return _allValues.TrimEnd(System.Environment.NewLine.ToCharArray());
}
を使用した簡単な解決策はありLinq
ますか?