Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 4th, 2012  |  syntax: None  |  size: 0.61 KB  |  hits: 15  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Is there a dictionary of dictionaries in QTP version of VBS?
  2. Dim dicParent : Set dicParent = CreateObject("Scripting.Dictionary")
  3.        
  4. >> Dim dicParent : Set dicParent = CreateObject("Scripting.Dictionary")
  5. >> dicParent.Add "Fst", CreateObject("Scripting.Dictionary")
  6. >> dicParent("Fst").Add "Snd", "child of parent"
  7. >> WScript.Echo dicParent("Fst")("Snd")
  8. >>
  9. child of parent
  10.        
  11. >> Dim dicParent : Set dicParent = CreateObject("Scripting.Dictionary")
  12. >> Dim dicChild  : Set dicChild  = CreateObject("Scripting.Dictionary")
  13. >> dicParent(dicChild) = "child of parent"
  14. >> WScript.Echo dicParent(dicChild)
  15. >>
  16. child of parent