IDataReader serialization error

m4gz

New Member
I have an ASP .net page which houses a Gridview. I am trying to bind an IDataReader object to the grid. Thsi IDataReader object is assigned by calling a few more layers of code(actually other .ent project dlls that form the Controller layer and the DB Layer) and then finally gets bounded to my grid.At gridview1.Datasource = dr (dr is my IDataReader), I dont see any problem.But at the line gridview1.Databind I get an exception and the details in the exception object are as follows:{"Type 'System.Data.Common.DbEnumerator' in Assembly 'System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' is not marked as serializable."}I am not sure on whats going wrong in the application. Any thoughts or comments?
 
Top