01 | <%@ Page Language="C#" AutoEventWireup="false" |
02 | CodeDatabase="Default.aspx.cs" Inherits="_Default" %> |
06 | < form id = "form1" runat = "server" > |
07 | An ASP.NET Database Processing Example |
08 | Name: < asp:TextBox ID = "authorName" runat = "server" Width = "150px" /> |
09 | Email: < asp:TextBox ID = "email" runat = "server" Width = "150px" /> |
10 | < asp:Button ID = "insert" runat = "server" Text = "Insert" /> |
11 | < asp:Button ID = "delete" runat = "server" Text = "Delete" /> |
12 | < asp:Button ID = "search" runat = "server" Text = "Search" /> |
14 | The search results are |
15 | < asp:Repeater ID = "searchResult" runat = "server" > |
18 | < tr bgcolor = "#b0c4de" > |
19 | < th >ID</ th >< th >Name</ th >< th >Email</ th > |
24 | < tr bgcolor = "#f0f0f0" > |
25 | < td ><%#DataBinder.Eval(Container.DataItem,"authorID")%></ td > |
26 | < td ><%#DataBinder.Eval(Container.DataItem,"authorName")%></ td > |
27 | < td ><%#DataBinder.Eval(Container.DataItem,"email")%></ td > |
31 | < FooterTemplate ></ table ></ FooterTemplate > |
|