Dictionary 相当于数组,每项数据都有唯一的关键字。
| set dic = Server.CreateObject("Scripting.Dictionary") |
| 属性/方法 | 意义 |
|---|---|
| Add(key, item) | 添加一个项目 |
| Exists(key) | 检测是否存在某关键字 |
| Items() | 返回一个数组,包含所有项目 |
| Keys() | 返回一个数组,包含所有关键字 |
| Remove(key) | 删除一个项目 |
| RemoveAll() | 清除所有内容 |
| Count | 项目总数 |
| Item(key) | 返回或设置项目 |
| Key(key) = newkey | 关键字改名,若没有则添加,值为空 |