← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #290844]: Problem with (cross) importing user-defined functions

 

Question #290844 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/290844

    Status: Open => Solved

Tu Mi confirmed that the question is solved:
I have the solution for this problem. Now it´s so simple :-)

>>> main.py (C:/firstProject/main.sikuli/main.py)
myScriptPath = "C:\\firstProject\\lib"
if not myScriptPath in sys.path: sys.path.append(myScriptPath)
from sikuli import *
from secondary import *
start()

>>> secondary.py (C:/firstProject/lib/secondary.py)
from sikuli import *
from images import *
def start():
 click(START_BUTTON)

>>> images.py (C:/firstProject/lib/images.sikuli/images.py)
START_BUTTON = "start_button.png"

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.