Click here to Skip to main content
15,888,113 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All

I am getting below error when I try to bind data to DataGrid
none
"object cannot be cast from dbnull to other type".

One important thing is that when i run this code in my local system it is working fine. after deployement , for first 2,3 times it is working fine but later only iam getting this error from server

I don't know why it is happening like this

And recently I added ICSharpCode.SharpZipLib.dll and Microsoft.Office.Interop.Excel.dll to solution.

Are these DLLs reason for error? Any relation?

Please help me out.
Posted
Updated 24-Feb-13 6:20am
v2
Comments
boogac 25-Feb-13 4:30am    
possible data loss while deploying ??

1 solution

data gridview only accepts data sources that are enumerable.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900