K
Karahan Celikel
I have a custom collection class subclassing the CollectionBase. Even if it
is marked as [Serializable] it gives an error when I try to store it in
viewstate. Following is the error message and stack trace info.
Error:
The type 'InTouch.Wip.Web.Admin.Content.WrappedContentCollection' must be
marked as Serializable or have a TypeConverter other than ReferenceConverter
to be put in viewstate
Stack:
HttpException (0x80004005): The type
'InTouch.Wip.Web.Admin.Content.WrappedContentCollection' must be marked as
Serializable or have a TypeConverter other than ReferenceConverter to be put
in viewstate.]
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +1480
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +764
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +739
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +847
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +872
System.Web.UI.LosFormatter.SerializeInternal(TextWriter output, Object
value) +102
System.Web.UI.Page.OnFormRender(HtmlTextWriter writer, String
formUniqueID) +143
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer)
+35
System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output) +262
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
ASP.Cm_aspx.__Render__control1(HtmlTextWriter __output, Control
parameterContainer) in xxxx.cs
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +27
System.Web.UI.Control.Render(HtmlTextWriter writer) +7
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
System.Web.UI.Page.ProcessRequestMain() +1929
Thanks in advance.
Karahan Celikel
is marked as [Serializable] it gives an error when I try to store it in
viewstate. Following is the error message and stack trace info.
Error:
The type 'InTouch.Wip.Web.Admin.Content.WrappedContentCollection' must be
marked as Serializable or have a TypeConverter other than ReferenceConverter
to be put in viewstate
Stack:
HttpException (0x80004005): The type
'InTouch.Wip.Web.Admin.Content.WrappedContentCollection' must be marked as
Serializable or have a TypeConverter other than ReferenceConverter to be put
in viewstate.]
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +1480
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +764
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +739
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +847
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +430
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +897
System.Web.UI.LosFormatter.SerializeValue(TextWriter output, Object
value) +872
System.Web.UI.LosFormatter.SerializeInternal(TextWriter output, Object
value) +102
System.Web.UI.Page.OnFormRender(HtmlTextWriter writer, String
formUniqueID) +143
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer)
+35
System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output) +262
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
ASP.Cm_aspx.__Render__control1(HtmlTextWriter __output, Control
parameterContainer) in xxxx.cs
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +27
System.Web.UI.Control.Render(HtmlTextWriter writer) +7
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
System.Web.UI.Page.ProcessRequestMain() +1929
Thanks in advance.
Karahan Celikel