Ask a Question

Scripts to accept parameters when called from keyword tests

SOLVED
hiepwork08
Contributor

Scripts to accept parameters when called from keyword tests

Hi,

I want to create a script whereby it takes in parameters, e.g.

 

function IsCheckBoxEnabled (String Label, Object LabelObj)

{

 ....

 return bool;

}

 

I then want to invoke IsCheckBoxEnabled from a keyword test and pass in the two input variables.

Question: I want to pass as input parameters from object properties of the application under test.

 

I am running in issues where TestComplete fails the syntax check for the IsCheckBoxEnabled. It's not happy with the input parameters bit.

If I change it to:

 

function IsCheckBoxEnabled()

{

}

 

Then the syntax passes.

 

Any ideas?

 

1 REPLY 1
hiepwork08
Contributor

I have solved this one.

it doesnt need the type.

correct syntax is just:

function IsCheckBoxEnabled (Label, LabelObj)

{

}

cancel
Showing results for 
Search instead for 
Did you mean: