当前位置: 首页 > 网络学院 > 服务端脚本教程 > ASP > ASP Item 属性

ASP
ASP 介绍
ASP Install
ASP 语法
ASP 变量
ASP Procedures
ASP Forms
ASP Cookies
ASP Session
ASP Application
ASP #include
ASP Global.asa
ASP Send e-mail
ASP Response
ASP Request
ASP Application
ASP Session
ASP Server
ASP Error
ASP FileSystem
ASP TextStream

ASP Item 属性


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-03-04   浏览: 317 ::
收藏到网摘: n/a

The Item property sets or returns the value of an item in a Dictionary object.
ASP Item属性的作用是设置或返回一个字典对象的元素(item)值

Syntax
语法

DictionaryObject.Item(key)[=newitem]

Parameter参数 Description描述
key Required. The key associated with the item
必要参数。指定与元素相联系的关键词
newitem Optional. Specifies the value associated with the key
可选参数。指定与关键词相联系的值

Example
举例

<%
Dim d
Set d=Server.CreateObject("Scripting.Dictionary")
d.Add "re","Red"
d.Add "gr","Green"
d.Add "bl","Blue"
d.Add "pi","Pink"
Response.Write("The value of key pi is: " & d.Item("pi"))
%>

Output:

The value of key pi is: Pink

评论 (0) All

登陆 | 还没注册?