New question #206539 on Sikuli:
https://answers.launchpad.net/sikuli/+question/206539
My Script read the path of a image (e.g.C:\GoogleSearch.png) from the file
C:\param.txt and perform exists(). Srtipt working from IDE and successfully
finds the image, but not working when running from command line a using .skl
file. Any clue?
Script:
try:
r=open("C:\param.txt",'r')
m=r.readlines()
k = ''.join(m)
popup (str(m))
r.close()
s = str(k)
popup(s)
if exists(s):
f = open("C:\out.txt", "w")
f.write("True")
f.close()
popup("if")
else:
f = open("C:\out.txt", "w")
f.write("False")
f.close()
popup("else")
except:
f = open("C:\out.txt", "w")
f.writelines("Unexpected error:"+ str(sys.exc_info()[0]))
f.writelines("\nUnexpected error:"+ str(sys.exc_info()[1]))
f.writelines("\nUnexpected error:"+ str(sys.exc_info()[2]))
f.close()
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.
_______________________________________________
Mailing list: https://launchpad.net/~sikuli-driver
Post to : [email protected]
Unsubscribe : https://launchpad.net/~sikuli-driver
More help : https://help.launchpad.net/ListHelp