Forum Discussion

guiramos's avatar
14 years ago

Getting a value from a cell in one array to define wich array should be used

Hello everyone!



This is my first post in this forum and I'm not sure if I'm posting in the right section...My apologies..



So, after hours of research I couldn't find a solution to this situation:



I have 5 arrays in my Project and the first array has one column that is used to define wich of the others four arrays TestComplete should access.



For example, Array 1 has a column called "TableReference". The first row of this column has the string value "Date1" and I need to access the array called "Date1". The second row of the column "TableReference" has the string value "Date2" and when I get this value, TestComplete should access the array called "Date2" and so on.



I was trying to use the code "Project.Variables.VariableByName...." with no success and I don't know how it should be done...



I hope I'm being clear enough... My english isn't good so if you guys couldn't understand the situation please tell me so I can try to explain in a different way.



I'm using Delphi, but any language might help.



Thanks guys!



Regards,



Guilherme Ramos

  • Hi Guilherme,





    Could you please describe the specific problem you faced with the VariableByName method in detail? Also, it will help if you post the entire script (or even the entire project suite) here.