3
Answers

How to insert images in dataGridView cells in C#?

Ken H

Ken H

10y
960
1
Hello friend,
    I had this requirement, I need to insert images in the dataGridView, It's path stored in the table.
In addition,When the mouse moves  to the photo area, the picture will be enlarged.

Table structure looks like this:
 
 ProductId  ProductName  ProductPicturePath Qty
 1  Product1 C:\MyImages\Product1.jpg  50
 2 Product2 C:\MyImages\Product2.jpg  10
 3 Product3 C:\MyImages\Product3.jpg 5

Please provide any good solutions.

Thanks.  
Answers (3)
0
Rajendra Tripathy

Rajendra Tripathy

NA 837 232.4k 10y

** I have already referred these 2 links for similar kind of requirement. 


http://csharp.net-informations.com/datagridview/csharp-datagridview-image.htm

http://www.codeproject.com/Articles/29383/Image-Thumbnail-Preview-in-DataGridView
Accepted
0
Ken H

Ken H

NA 642 252.5k 10y
I need is based on the dataGridView.  Non-GridView.

Thank.
0
Ankur Jain

Ankur Jain

NA 1.2k 115.5k 10y
Hi!
look at the below thread..
http://www.c-sharpcorner.com/UploadFile/5089e0/show-image-in-gridview-using-Asp-Net/
http://www.aspdotnet-suresh.com/2011/03/how-to-save-images-into-folder-and.html

for zoom image..
http://yasserzaid.wordpress.com/2010/05/09/use-mouseover-on-image-in-gridview-to-zoom-image/
http://forums.asp.net/t/1441945.aspx?To+enlarge+the+image+on+mouseover+in+a+gridview