📜  string.QueryString c# 代码示例

📅  最后修改于: 2022-03-11 14:49:05.208000             🧑  作者: Mango

代码示例1
var queryString = QueryHelpers.ParseQuery("?param1=value");
  // queryString.GetType() --> typeof(Dictionary)

  // Adding a parameter
  queryString.Add("param2", "my value"); // Easy so far.

  // Adding a second parameter with the same name
  queryString.Add("param2", "my other value"); // ArgumentException!
  // --> An item with the same key has already been added