Cycle de progression Faire (quelque chose qui marche) -> comprendre ce que l’on fait/comment cela marche -> pousser plus loin les notions
| <form id="form1" runat="server"> <div> <br /> <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" OnSelecting="ObjectDataSource1_Selecting" SelectMethod="GetContacts" TypeName="ContactCaching.BLL.ContactCtrl" EnableCaching="True" SqlCacheDependency="ContactDB:Contact"> </asp:ObjectDataSource> <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label></div> <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataSourceID="ObjectDataSource1"> <Columns> <asp:BoundField DataField="ContactID" HeaderText="ContactID" SortExpression="ContactID" /> <asp:BoundField DataField="Contactname" HeaderText="Contactname" SortExpression="Contactname" /> <asp:BoundField DataField="ContactAge" HeaderText="ContactAge" SortExpression="ContactAge" /> <asp:BoundField DataField="ContactCategoryID" HeaderText="ContactCategoryID" SortExpression="ContactCategoryID" /> </Columns> </asp:GridView> </form> |
| <?xml version="1.0"?> <configuration> <appSettings/> <connectionStrings> <add name="connectionString1" connectionString="Data Source=.;Initial Catalog=ContactDB;Integrated Security=SSPI;" providerName="System.Data.SqlClient"/> </connectionStrings> <system.web> <caching> <sqlCacheDependency enabled="true" pollTime="1000"> <databases> <add name="ContactDB" connectionStringName="connectionString1"/> </databases> </sqlCacheDependency> </caching> <compilation debug="true"/> <authentication mode="Windows"/> </system.web> </configuration> |