[HowTo] use functions with parameters
Asked by
Calle Rundgren
I want my script to be as universal as possible. For example I want to find a image on screen, in order to make it easy to switch and search for another image I think it would be great to use parameters.
class findGuiElement:
def __init__(self, image1, image2, image3):
self.image1 = image1()
self.image2 = image2()
self.image3 = image3()
def findElement(image1, image2, image3):
if exists("a universal str for image"):
When calling the function I think it would be something like this:
findGuiElement(
If I for example want to find image1.
Does anyone know how to execute this properly?
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- SikuliX Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- RaiMan
- Solved:
- Last query:
- Last reply:
To post a message you must log in.