how to get query string parameter in c# code example
Example 1: get query string parameter from string value c#
Uri myUri = new Uri("http://www.example.com?param1=good¶m2=bad");
string param1 = HttpUtility.ParseQueryString(myUri.Query).Get("param1");
Example 2: string.QueryString c#
StringValues twoValues = StringValues.Concat(queryString["param2"], "my other value");
parsedQueryString["coronavirus"] = twoValues;
var param2Value = queryString["param2"];
param2Value.ToString();
param2Value.ToArray();
queryString["param1"] = "another value";
QueryString.Create(parsedQueryString).ToString();