Invalid Number of Paramters
Don't know what I am doing wrong but I am trying to use an If..Then...Else statement that used to work in TestComplete v11. I have upgraded to v12 and no matter what I do the test fails and displays the error "Invalid number of parameters". I am trying using a data driven test and I have data in my excel spreadsheet that works everywhere else on my form except when I am trying to test for and select either a Male or Female gender button based on what I have in my spread sheet.
Basically I have it like this:
If....
Value 1 is set to: ProjectSuite.Variables.Donation_Data("Gender")
Condition: Equals
Value2: Male
Then...
Select the Male button
Else...
Select the Female button
what other parameters am I missing?????? any help would be appreciated!!!
I'm assuming that the function you posted, when you did it as a keyword test, was being called inside a Data-Driven loop like so..
so... your call to the data field of Gender IS correct... that means, then, that the problem is not in the gender call but something within the subsequent logic of clicking the buttons.
As a diagnostic, try just doing a quick script record of clicking on the buttonMale and see how it shows up. It's entirely possible that "ClickButton()" might not be the correct method call... If you don't want to try to record, try replacing "ClickButton()" with just "Click()"and see if that corrects it.