1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | < asp:GridView ID = "gvEmployees" runat = "server" AutoGenerateColumns = "False" pagesize = "5" AllowPaging = "True" > < Columns > < asp:BoundField DataField = "Name" HeaderText = "Name" /> < asp:BoundField DataField = "Team" HeaderText = "Team" /> < asp:BoundField DataField = "dateHired" HeaderText = "Date Hired" DataFormatString = "{0:MMMM dd, yyyy}" /> < asp:BoundField DataField = "empStatus" HeaderText = "Employment Status" /> < asp:BoundField DataField = "birthday" HeaderText = "Birthday" /> < asp:BoundField DataField = "civilStatus" HeaderText = "Civil Status" /> < asp:BoundField DataField = "noOfChildren" HeaderText = "No. Of Children" /> < asp:BoundField DataField = "cellphoneNo" HeaderText = "Cellphone #" /> < asp:BoundField DataField = "address" HeaderText = "Address" /> < asp:BoundField DataField = "contactPerson" HeaderText = "Contact Person" /> < asp:BoundField DataField = "contactNo" HeaderText = "Emergency #" /> < asp:TemplateField > < ItemTemplate > < asp:Image ID = "Image1" runat = "server" ImageUrl ='<%# "~/Images/EmpImage/"+Eval("idemployee").tostring()+".png" %>' /> </ ItemTemplate > </ asp:TemplateField > </ Columns > |
Friday, September 21, 2012
Gridview with ImageURL
Labels:
asp.net,
datagrid,
web development
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment