Why can't page methods have parameters with the same name but with different casing?

Published Wed, Nov 15 2006 16:43

Short answer: because the internal WebServiceMethodData class is using a Dictionary<string, WebServiceParameterData> and is using the StringComparer.OrdinalIgnoreCase comparer which, as the name suggests, is responsible for performing a case insensitive comparison (in practise, this means that id equals ID, equals Id, etc).

Special thanks to Garbin for pointing the obvious :)

It's important to note that this will be fixed in the next release: http://forums.asp.net/1466410/ShowThread.aspx#1466410

Filed under: ,

Leave a Comment

(required) 
(required) 
(optional)
(required)