扫一扫
分享文章到微信
扫一扫
关注官方公众号
至顶头条
<html> <script language="VB" runat=server> Sub Page_Load(Sender As Object, E As EventArgs) Message.InnerHtml = "Welcome to ASP.NET" End Sub </script> <body> <span id="Message" style="font-size:24" runat=server/> </body> </html> |
<asp:datalist id="MyList" runat=server> <ItemTemplate> Here is a value: <%# Container.DataItem %> </ItemTemplate> </asp:datalist> |
<html> <script language="VB" runat=server> Sub Page_Load(Sender As Object, E As EventArgs) Dim Items As New ArrayList Items.Add("One") Items.Add("Two") Items.Add("Three") MyList.DataSource = Items MyList.DataBind() End Sub </script> <body> <asp:datalist id="MyList" runat=server> <ItemTemplate> Here is a value: <%# Container.DataItem %> </ItemTemplate> </asp:datalist> </body> </html> |
<html> <script language="VB" runat=server> Sub Page_Load(ByVal Sender As Object, ByVal E As EventArgs) ArrayItems.Add("One") ArrayItems.Add("Two") ArrayItems.Add("Three") MyList.DataSource = ArrayItems MyList.DataBind() End Sub </script> <body> <object id="ArrayItems" class="System.Collections.ArrayList" runat=server/> <asp:datalist id="MyList" runat=server> <ItemTemplate> Here is a value: <%# Container.DataItem %> </ItemTemplate> </asp:datalist> </body> </html> |
<html> <body> The below content has been hidden from browser clients using a server-side comment (view the .aspx source to see what we mean :-) <%-- <asp:calendar id="MyCal" runat=server/> <% For I = 0 To 44 %> Hello World <br> <% Next %> --%> </body> </html> |
<html> <body> <!-- #Include File="Header.inc" --> <br /> <h3> Main page content </h3> <br /> <!-- #Include File="Footer.inc" --> </body> </html> |
<asp:SqlDataSource ID="SqlDataSource1" ConnectionString='<%$ connectionStrings:Pubs %>' runat="server" SelectCommand="sp_GetAuthors" /> <asp:Label ID="Label1" Text='<%$ Resources: ExchRate, ConvertLabel %>' runat="server"/> |
如果您非常迫切的想了解IT领域最新产品与技术信息,那么订阅至顶网技术邮件将是您的最佳途径之一。
现场直击|2021世界人工智能大会
直击5G创新地带,就在2021MWC上海
5G已至 转型当时——服务提供商如何把握转型的绝佳时机
寻找自己的Flag
华为开发者大会2020(Cloud)- 科技行者