karthiknbc 0 Unverified User

Hi,

I migrated the session state from "InProc" to "SqlState" by making the classes serializable, and the application works fine by retrieving data from the database and displaying it on the forms but the error message displays as follows when i try to save any information into the database from the application.

http://localhost:3573/Forms/NewAccou...FD5935B85296A9
Error Message:Type 'System.Data.SqlClient.SqlTransaction' in Assembly 'System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' is not marked as serializable.
Stack Trace: at System.Runtime.Serialization.FormatterServices.InternalGetSerializableMembers(RuntimeType type)
at System.Runtime.Serialization.FormatterServices.GetSerializableMembers(Type type, StreamingContext context)
at System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo.InitMemberInfo()
at System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo.InitSerialize(Object obj, ISurrogateSelector surrogateSelector, StreamingContext context, SerObjectInfoInit serObjectInfoInit, IFormatterConverter converter, ObjectWriter objectWriter)
at System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo.Serialize(Object obj, ISurrogateSelector surrogateSelector, StreamingContext context, SerObjectInfoInit serObjectInfoInit, IFormatterConverter converter, ObjectWriter objectWriter)
at System.Runtime.Serialization.Formatters.Binary.ObjectWriter.Write(WriteObjectInfo objectInfo, NameInfo memberNameInfo, NameInfo typeNameInfo)
at System.Runtime.Serialization.Formatters.Binary.ObjectWriter.Serialize(Object graph, Header[] inHeaders, __BinaryWriter serWriter, Boolean fCheck)
at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Serialize(Stream serializationStream, Object graph, Header[] headers, Boolean fCheck)
at System.Web.Util.AltSerialization.WriteValueToStream(Object value, BinaryWriter writer)
2010-09-23 13:31:07,959 [4072] ERROR TAG.DO.WebUI.Global - Exception occured in Application_Error(); Error Message: Object reference not set to an instance of an object.; StackTrace: at TAG.DO.WebUI.Global.Application_Error(Object sender, EventArgs e) in D:\DOSource14Sep\DO-Product\DO-WebUI\Global.asax.cs:line 271