Make the HttpValueCollection class public and move it to System.dll - by Paulo Morgado

Status : 

  Won't Fix<br /><br />
		Due to several factors the product team decided to focus its efforts on other items.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.


23
1
Sign in
to vote
ID 356144 Comments
Status Closed Workarounds
Type Suggestion Repros 10
Opened 7/14/2008 4:56:55 PM
Access Restriction Public

Description

The HttpValueCollection class is very usefull not only to handle requests inside ASP.NET but also to build requests on any platform: Windows Client applications, Windows Service applications, Silverlight applications, Windows Mobile applications.
Sign in to post a comment.
Posted by duke.ua on 8/19/2009 at 5:00 AM
HttpValueCollection is a very important class to use in web application. For a quick example: how would you handle making a hyperlink on your page that would have current querystring, except for the certain name/value pair? You cannot do .Remove() because Request.QueryString is a read-only collection. So you need to make your own instance of it and plain NameValueCollection class doesn't help with nifty .ToString() stuff that you would want to have in this case.

How hard could it be to just make the HttpValueCollection class public in it's namespace?
Posted by Paulo Morgado on 8/13/2008 at 12:45 PM
However, I don’t think you can infer the usage of a particular class by its usage inside the framework, even with something as hidden as the HttpValueCollection class.

The string representation of a name/value collection as used in HTTP is very useful and a standard way of representing a name/value collection as a string. Not only to parse requests, but also to build requests and even, for example, in XML configuration files.

As of last week, every desktop installation of the .NET framework had the System.Web assembly. That may no longer be the case with the client profile introduced by .NET 3.5 SP1. Adding to that, there’s the Compact Framework, XNA, Silverlight and who knows what, all wanting to communicate with the cloud.

I fully understand all contingencies around software development and thank you for taking the time to provide feedback to my suggestion.
Posted by Microsoft on 8/12/2008 at 6:20 PM
As part of developing the next major version of the .NET Framework we reviewed this request. However as with all software development we have to balance development resources against all of the incoming enhancement requests.

Since HttpValueCollection is a comparatively little-used type that is specific to ASP.NET development scenarios we don't have any plans at this type to refactor the type into a common namespace and assembly.

Thank you again for submitting your suggestion.