三度网教程:是一个免费提供流行视频软件教程、在线学习分享的学习平台!

asp+中的hash表设置

时间:2024-1-29作者:未知来源:三度网教程人气:


/*
豆腐制作 都是精品
http://www.asp888.net 豆腐技术站
如转载 请保留版权信息
*/
Hash 表是一组包含有Key 和 Value 数据 的表,我们可以通过 下面的这个例子 看看如何操作Hashtable
<html>
<head>

<script language="VB" runat="server">
Sub Page_Load( s As Object, e As EventArgs )
If Not IsPostBack Then
Dim myHash As New HashTable()
myHash.Add( "ASP+", "1" )
myHash.Add( "COM+", "2" )
myHash.Add( "ADO+", "3" )
myHash.Add( "C#", "4" )
MyRepeater.DataSource = myHash
MyRepeater.DataBind
End If
End Sub
</script>

</head>
<body>

<h3>请看这是一个在 DataSet 上绑定一个 哈稀表 的操作代码</h2>

<form runat=server>

<asp:Repeater id="MyRepeater" runat="server">

<template name="itemtemplate">
<br>
<%# Container.DataItem.Key %> :


<%# Container.DataItem.Value %>
</template>

</asp:Repeater>

</form>

</body>
</html>

作者:豆腐()


关键词:  asp+中的hash表设置





Copyright © 2012-2018 三度网教程(http://www.3du8.cn) .All Rights Reserved 网站地图 友情链接

免责声明:本站资源均来自互联网收集 如有侵犯到您利益的地方请及时联系管理删除,敬请见谅!

QQ:1006262270   邮箱:kfyvi376850063@126.com   手机版