如何根据需要在具有固定尺寸的数据库中的网格视图中显示图像 [英] how to show image in a gridview from database with a fixed dimension as we want
本文介绍了如何根据需要在具有固定尺寸的数据库中的网格视图中显示图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何根据需要在具有固定尺寸的数据库中的网格视图中显示图像
how to show image in a gridview from database with a fixed dimension as we want
推荐答案
请参阅本文,以显示数据库中的图像:
http://www.aspsnippets. com/Articles/Display-images-from-SQL-Server-Database-in-ASP.Net-GridView-control.aspx [
Refer to this article to show image from database:
http://www.aspsnippets.com/Articles/Display-images-from-SQL-Server-Database-in-ASP.Net-GridView-control.aspx[^]
Set fixed dimension by changing ControlStyle-Width and ControlStyle-Height attributes:
<asp:ImageField DataImageUrlField = "ID"
DataImageUrlFormatString = "ImageCSharp.aspx?ImageID={0}"
ControlStyle-Width = "100" ControlStyle-Height = "100"
HeaderText = "Preview Image"/>
这篇关于如何根据需要在具有固定尺寸的数据库中的网格视图中显示图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文