Following our efforts to get our ASP.NET sites working correctly in IE10 - specifically, trying to fix the IE10 bug when the server doesn't recognize the UA string and linkbuttons fail to trigger the postback..., I have copied the ie.browser file to my App_Browsers folder.
ref: Hanselman's http://www.hanselman.com/blog/BugAndFixASPNETFailsToDetectIE10CausingDoPostBackIsUndefinedJavaScriptErrorOrMaintainFF5ScrollbarPosition.aspx
For various reasons, I cannot apply the machine-wide fix. My server is running .NET 3.5, I cannot update it either.
For most of our sites, the fix works like a charm. For some sites, it seems it either doesn't work at all, or breaks the site and gives an error. Those sites make use of the CSSFriendly toolkit and thus already have a .browser file which has the following content:
<browsers>
<browser refID="Default">
<controlAdapters>
<adapter controlType="System.Web.UI.WebControls.TreeView"
adapterType="SVCN.CSSFriendly.TreeViewAdapter" />
</controlAdapters>
</browser>
<browser id="W3C_Validator" parentID="default">
<identification>
<userAgent match="^W3C_Validator" />
</identification>
<capabilities>
<capability name="browser" value="W3C Validator" />
<capability name="ecmaScriptVersion" value="1.2" />
<capability name="javascript" value="true" />
<capability name="supportsCss" value="true" />
<capability name="supportsCallback" value="true" />
<capability name="tables" value="true" />
<capability name="tagWriter" value="System.Web.UI.HtmlTextWriter" />
<capability name="w3cdomversion" value="1.0" />
</capabilities>
</browser>
</browsers>
When I get an error, it's the following:
Input string was not in a correct format.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.FormatException: Input string was not in a correct format.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[FormatException: Input string was not in a correct format.]
System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +7470007
System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +119
System.Version..ctor(String version) +259
System.Web.Configuration.HttpCapabilitiesBase.get_MSDomVersion() +52
System.Web.UI.WebControls.TreeView.EnsureRenderSettings() +96
System.Web.UI.WebControls.TreeView.OnPreRender(EventArgs e) +43
System.Web.UI.Control.PreRenderRecursiveInternal() +80
System.Web.UI.Control.PreRenderRecursiveInternal() +171
System.Web.UI.Control.PreRenderRecursiveInternal() +171
System.Web.UI.Control.PreRenderRecursiveInternal() +171
System.Web.UI.Control.PreRenderRecursiveInternal() +171
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.3615; ASP.NET Version:2.0.50727.3053
I have tried a combination of things without success. Did anybody encounter such a problem ?
Thanks for your help.