System.NotSupportedException: Collection is read-only

F

fero

Hello,
I have the following problem. I have a page which works fine. But
sometimes I see the following error in error log:


-- Message: System.Web.HttpUnhandledException: Exception of type
System.Web.HttpUnhandledException was thrown. --->
System.NotSupportedException: Collection is read-only.
at System.Collections.Specialized.NameValueCollection.Add(String
name, String value)
at System.Web.HttpValueCollection.FillFromEncodedBytes(Byte[] bytes,
Encoding encoding)
at System.Web.HttpRequest.FillInQueryStringCollection()
at System.Web.HttpRequest.get_QueryString()
at System.Web.UI.Page.GetCollectionBasedOnMethod()
at System.Web.UI.Page.DeterminePostBackMode()
at System.Web.UI.Page.ProcessRequestMain()
--- End of inner exception stack trace ---
at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain()
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication+IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step,
Boolean& completedSynchronously)


I see that a code tries to write to read-only collection. But the
question is why ? It's not my code ... it happens only sometimes... .
Any ideas ?

Thanks.

Regards,
Fero
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top