I have declared and assigned a value to a variable in my Action. There is a function present in a function library associated with this Test/Action. Now, I expected the function to know the value of this variable. But it is not so. The variable is shown as 'Empty' in watch. What should I do to use that variable in the function? Here is the snipped code:
fileLocation = "C:\Loads.xls"
In Function Library:
Public Function Func1()
currentFile = fileLocation
I want fileLocation to be known to Func1().
With Warm Regards,
You can easily judge the character of others by how they treat those who can do nothing for them or to them.
Your original question is a QTP unique "namespace" issue, which is not well (or perhaps at all) covered in the standard documentation. Here is a thread that has a small document attached that should provide some additional information as to why you had to move your global variable to a shared lib: