Posted on: 2/11/2014 8:09:56 PM | Views : 792

I have managed to store image in the database (trough Image type in database which is actually byte array), but I can't display that image in GridView. First when I see GridView, it is showing all columns except for Photo column which is suppose to display the image from database. I didn't write any code to display data in GridView. I have just attach data source to that GridView in designer. Not displaying image is not the only problem. I have allowed editing and deleting in the GridView, and when I want to save the changes of editing, I get this message:
Server Error in '/' Application. Operand type clash: sql_variant is incompatible with image Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Data.SqlClient.SqlException: Operand type clash: sql_variant i ...

Go to the complete details ...