我如何将图像插入数据库并再次选择它 [英] how can i insert an image into database and select it again

查看:72
本文介绍了我如何将图像插入数据库并再次选择它的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想插入一个图像,然后从数据库中再次选择它到图片框,我已经成功地将它插入数据库(图像列)中,但是当我再次选择它时,出现错误参数无效",我认为该插入语句有错误,是否有任何代码示例可用于将图像插入数据库并再次选择?

谢谢.

i want to insert an image and select it again from database into picturebox i have succeeded to insert it into database (image column) but when i select it again i get an error "The Parameter Is Not Valid" i think the insert statement has something incorrect,any sample of code for inserting an image into database and select it again?

Thanks.

推荐答案

以字节为单位更改图像,然后在数据库中插入"和检索时间"中再次检索该字节并再次转换.
Change your image in byte and then Insert in DataBase and Retrieve time retrieve that byte again and convert it again.


检查这些答案

在Sqlserver表中存储图像 [如何使用Asp在数据库中保存和检索图像.net [
Check these answers

Storing Image in Sqlserver table[^]
How to save and retrieve Image in Database using Asp.net[^]


这篇关于我如何将图像插入数据库并再次选择它的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆