为啥我数据库的图片不能输出.System.Byte
doc字段对应应该是图片的,为啥输出System.Byte
html:
<asp:GridView ID= "GridView1 " runat= "server " DataKeyNames= "docID " AutoGenerateColumns= "False ">
<Columns>
<asp:BoundField DataField= "docid " HeaderText= "docID " />
<asp:BoundField DataField= "doctitle " HeaderText= "doctitle " />
<asp:BoundField DataField= "doctype " HeaderText= "doctype " />
<asp:TemplateField HeaderText= "doc ">
<ItemTemplate>
<%# Eval( "doc ")%>
</ItemTemplate>
<EditItemTemplate>
<asp:Image ID= "Image1 " runat= "server " Value= ' <%# Eval( "doc ") %> '/>
</EditItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
服务器端:
protected void Page_Load(object sender, EventArgs e)
{