I was trying some serialization of an ODBCDataReader object in C# when I ran into this problem. I'll put below the whole scenario.
There is a particular class which has a public property which is an ODBCDataReader. One of the methods in the class updates this data reader. The problem occurs when I try to access the data reader object from another class. Even though the watches show that the object's hasRows as true, when I try to at least display it using a ToString(), it gives an error saying that the object reference is null.
I'm extremely sure that the data reader is returned a not null value and I have used the data reader objects elsewhere without any problems. I think the porblem is in assigning the data reader as a public property. (I tried to create another data reader object and equal it to this and it still gives a null error
OdbcDataReader a = X.dbReader;
where X is the class I was talking about and dbReader is the property that I was talking about. When I 'watch' a, it shows 'a' as a null.)
Can someone help me with this Is there sort of a limitation in referncing ODBCDataReaders

ODBCDataReader identified as a null