link.ascx

来自「ASP_NET程序设计教程 源代码 冶金工业出版社 肖金秀 冯沃辉 陈少涌」· ASCX 代码 · 共 30 行

ASCX
30
字号
<% @ Import Namespace="Packaging" %>
<% @ Import Namespace="System.Data" %>
<script language="VB" runat="server">
	Sub Page_Load(Sender As Object, e As EventArgs)
		Dim MyLink As linkDB=New LinkDB()
		Dim DV As DataView=MyLink.GetLinks()
		linklist.DataSource=DV
		linklist.DataBind()
	End Sub
</script>
<% @ Control %>
<asp:Panel id="link" align="center" runat="server">
	<table border="0" cellpadding="0" cellspacing="0" width="90%" height="130">
		<tr><td width="100%" align="center">
		<table border="0" cellpadding="0" cellspacing="0" width="90%" height="104">
			<tr><td width="100%" background="images/bar.gif" height="18" class="bar">&nbsp;LINKS</td></tr>
			<tr><td width="100%" bgcolor="#E7F4DD" height="86" align="center">
			<table border="0" cellpadding="0" cellspacing="0" width="90%">
<asp:Repeater id="linklist" runat="server">
	<ItemTemplate>
				<tr><td width="100%">
<a href="<%# DataBinder.Eval(Container.DataItem, "linkUrl") %>" class="author" target="_blank"><%# DataBinder.Eval(Container.DataItem, "linkText") %></a>
				</td></tr>
	</ItemTemplate>
</asp:Repeater>
			</table></td></tr>
		</table></td></tr>
	</table>
</asp:Panel>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?