Contributions
Re: JavaScript Scripting.Dictionary Keys() and Items() not work...
Hi Jared, thank your help!!, it's work. fallow is my code. function alarmgo3() { dicTmp = new ActiveXObject("Scripting.Dictionary"); dicTmp.add("Abc", "abc"); dicTmp.add("Abd", "abc"); dicTmp.add("Abe", "abc"); dicTmp.add("Abf", "abc"); keys_d = dicTmp.Keys(); useVBArray = new VBArray(keys_d) resArray = useVBArray.toArray(); for (var index=0; index< dicTmp.Count; index++) { Log.Message(resArray[index]);//it is work !! } }3.2KViews0likes0CommentsJavaScript Scripting.Dictionary Keys() and Items() not work...
HI all: The document says the dictionary Keys() and Items() return a array that hold the values for keys/values but I cannotretrievevalues from return array, fallow is my code function alarmgo2() { dicTmp = new ActiveXObject("Scripting.Dictionary"); dicTmp.add("Abc", "abc"); dicTmp.add("Abd", "abc"); dicTmp.add("Abe", "abc"); dicTmp.add("Abf", "abc"); keys_d = dicCooling.Keys(); for (var index=0; index< dicTmp.Count; index++) { Log.Message(keys_d[index]);//it log none in the log } } Please help me!! did I do some thing wrong? or It is TC's BUG? Have a good day. AlarmChang22KViews0likes2Comments