Micro Focus QTP (UFT) Forums

Full Version: QTP vbscript ArrayList strange behavior
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This might be self-explanatory, but I realy don't understand what's wrong. It would be great if someone else saw it, and enlightened me.

If I try using the value in an ArrayList directly, with QTP's LoadAndRun function, it doesn't work. However, if I copy the values from the ArrayList into variables first, then it works.

This works:

Code:
test1 = testActionArray(1)(0)
test2 = testActionArray(1)(1)

LoadAndRunAction "C:\share\Test Automation\Flight Reservation Application\UFT Tests\" & test1,test2, oneIteration

But this does NOT work:

Code:
LoadAndRunAction "C:\share\Test Automation\Flight Reservation Application\UFT Tests\" & testActionArray(1)(0),testActionArray(1)(1), oneIteration

It's the same ArrayList, in the same script. When doing this in a normal vbscript, it works as expected. But if I try to use it with LoadAndRunAction in QTP, it simply doesn't work.

Anyone got any ideas?
Is there any activity in this Forum at all?
I have only used the dotnet arrayList after loading QTP and it looks very different from what you are doing.

sorry,

Parke