using System; using System.Collections.Generic; using System.Linq; using System.Web; namespace MyWebApp { public class MyPage : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { string name = Request.QueryString["name"]; string age = Request.QueryString["age"]; Response.Write("Name: " + name + ", Age: " + age); } } }
using System; using System.Collections.Generic; using System.Linq; using System.Web; namespace MyWebApp { public class MyPage : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { string name = Request.Form["name"]; string age = Request.Form["age"]; Response.Write("Name: " + name + ", Age: " + age); } } }In this example, the HttpRequest object is used to retrieve the name and age form data from a POST request. The values are then written out to the response. The System.Web namespace is part of the .NET Framework and does not require any external libraries.