I have a question about converting a datareader
to datatable
. In my code, I have a datareader
created in one class and passed to another class that I want to convert to datatable
.
When I do this, it does not work as the table remains empty. If I do the conversion in the same function, it works fine.
The only thing when I pass the datareader
another function that stops working . Is it because dr
closed or something else? How do I solve this problem? Any help would be great.
jason source share