Results 1 to 2 of 2

Thread: Dictionary

  1. #1
    Join Date
    Dec 1969

    Default Dictionary

    I have heard and look at codes using dictionary objects in asp and still do not get it. Could anybody tell me what they are used for and why. I need to get a fast understanding and point me to resources.<BR><BR>thanks

  2. #2
    Join Date
    Dec 1969

    Default RE: Dictionary

    The dictionary object is cool. It gives you the power to reference your varibles by a string name. <BR><BR>set myDic = server.createObject("scripting.dictionary")<BR><BR >myDic("foobar")="hello my name is foobar"<BR>myDic("aspRocks") = "Asp rocks"<BR><BR>you get the picture. You dont have to use the add method or whatever as soon as you assign a value to a string it becomes valid. You can grab an array of the keys by doing<BR><BR>myDicKeys = myDic.keys<BR>&#039and now you can iterate through an array<BR>for each key in myDicKeys<BR> response.write myDic(key)&"<BR>"<BR>next<BR><BR>check microsoft for all the properties and methods.<BR><BR>http://msdn.microsoft.com/library/default.asp?URL=/library/devprods/vs6/vbasic/vbenlr98/vaobjDictionary.htm

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts