I have an asp application that uses vbscript. There is a dictionary object
that is included in this application.
I want to be able to see all the members that are part of a dictionary
object. Thus I have the following questions:

1. What do I need to do to be able to see the count of the number of
members included in the dictionary object?
2. What can I do to see what is included in each member of the dictionary
object? In other words, I would like to all the data contained in each
occurence of the dictionary object.

Re: using vbscript with a dictionary object by de

de
Tue Mar 15 20:46:38 CST 2005

set dic = CreateObject("Scripting.Dictionary")

dic("a") = "eh"
dic("b") = "bee"
dic("c") = "see"

wscript.echo "numkeys=",dic.Count

'dump all keys and values

for each key in dic.Keys
wscript.echo "key=" & key,"entry=" & dic(key)
next

'dump just the values

for each item in dic.Items
wscript.echo "item=" & item
next



Re: using vbscript with a dictionary object by WendyElizabeth

WendyElizabeth
Wed Mar 16 08:59:02 CST 2005

Thank you this information helped alot!

"de Graff" wrote:

> set dic = CreateObject("Scripting.Dictionary")
>
> dic("a") = "eh"
> dic("b") = "bee"
> dic("c") = "see"
>
> wscript.echo "numkeys=",dic.Count
>
> 'dump all keys and values
>
> for each key in dic.Keys
> wscript.echo "key=" & key,"entry=" & dic(key)
> next
>
> 'dump just the values
>
> for each item in dic.Items
> wscript.echo "item=" & item
> next
>
>
>