Friday, 1 April 2011
request.params and request.querystring
Request.Params and Request.Querystring both are collection types holding key/value pairs. But Params is ths super set of all as it holds all the form fields values posted back, querystring parameter values.
Whereas Request.Querystring holds only those parameters that are passed as a querystring in the page URL like http://myapplicationpage.aspx?Id=1&Name=PankajSharma&Profession=Software+Developer. So the Id, Name & Profession are the query string paramters and they will be available in both collections.
But if there were textboxes for capturing these fields on the form then these values would not be available in QuerySTring Collection but they will be available in Params collection.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment