Data Binding ASP.Net Tutorial

<%@ Page Language="C#" %>
   "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">


    
    
            id="frmProducts"
        DataSourceID="srcProducts"
        DataKeyNames="Id"
        AllowPaging="true"
        Runat="server">
        
        

<%# Eval("Title") %>


        Directed By:
        <%# Eval("Director") %>
        
        In Theaters:
        <%#Eval("InStock") %>
        
                    id="lnkDelete"
            Text="Delete Product"
            CommandName="Delete"
            OnClientClick="return confirm('Are you sure?');"
            Runat="server" />
        

    
            id="srcProducts"
        ConnectionString="<%$ ConnectionStrings:Products %>"
        SelectCommand="SELECT Id,Title,Director,InStock
            FROM Products"
        DeleteCommand="DELETE Products WHERE Id=@Id"
        Runat="server" />
    

    


File: Web.config

  
             connectionString="Data Source=.\SQLEXPRESS;
         AttachDbFilename=|DataDirectory|MyDatabase.mdf;Integrated Security=True;User Instance=True" />