Ask a Question

Script Routine Parameters

SOLVED
ianlop
Occasional Contributor

Script Routine Parameters

Hello,

 

I have written a parameterized script routine in python and I want to use it in a keyword test. But these parameters are an on-screen object's Property names and values.

The first parameter i have is 'PropNames' and the second one is 'PropValues'. Where they must accept the list format in python: ['A', B',....].

Which option would that be in the list below?

ianlop_0-1680298184887.png

 

Thank you

 

4 REPLIES 4
rraghvani
Trusted Contributor

See the example shown in Parameterizing Script Routines for keyword test.

ianlop
Occasional Contributor

The documentation does not give an example on what I am looking for. I want to pass a list as an argument that my python method needs. Which of these options is that and how would I input that in?

 

Here's an example on what I mean:

def foo(LstParam1=[], LstParam2=[]):
        #code
        ////

ianlop_0-1681141570496.png

I can see that the only options would be Object Or Variant. Which one is it and how would I enter it in?

Thank you

rraghvani
Trusted Contributor

Here's an example of using Code Expression to pass a list of strings, in a Run Script Routine keyword test

rraghvani_0-1681200175545.png

 

ianlop
Occasional Contributor


@rraghvani wrote:

Here's an example of using Code Expression to pass a list of strings, in a Run Script Routine keyword test

rraghvani_0-1681200175545.png

 


Thank you

cancel
Showing results for 
Search instead for 
Did you mean: