How to convert byte array to image and display in datagrid?

前端 未结 2 1514
没有蜡笔的小新
没有蜡笔的小新 2020-12-22 04:33

I have made a sql database using sql server. This database include images. When I display this database in a datagrid, byte[]array displays in the image column. How do I con

2条回答
  •  南方客
    南方客 (楼主)
    2020-12-22 04:55

    Try

     MemoryStream ms = new MemoryStream(imageBytes);
     Image image= Image.FromStream(ms);
    

提交回复
热议问题