← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #389068]: Running script from command line with parameter

 

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

Rom posted a new comment:
Hi RaiMan,

thanks for the quick response, appreciate it.

I created scripts to automate installation of certain applications like
firefox, avbrowser, etc. SikuliSharp is a C# wrapper that provides an
interface to call sikuli scripts. Anyway, I can actually get the
parameter. However, what i noticed is that app.open did not open the
installer. Based from the log, App.focus : [2148: cmd.exe], it should be
the absetup.exe as it is what I'm trying to open.


runsikulix.cmd -r my-script.sikuli --args 'absetup.exe'


import sys
#name = "absetup.exe"
name = sys.argv[1]
print(name)

s = Screen()
myApp = App(name)

if not myApp.window():
    myApp.open(10)
    s.wait(10)
    
myApp.focus()
wait(5)
click("Install.png")
s.wait(10)
click("CheckBox.png")
s.wait(1)
click("Finish.png")

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