← Back to team overview

sikuli-driver team mailing list archive

[Question #231816]: open a SWING GUI by running a Sikuli script

 

New question #231816 on Sikuli:
https://answers.launchpad.net/sikuli/+question/231816

Hi,

I'm using the last sikuli version (1.0.0 - May 2013) running on a Windows7 - 64 bit with Java jre-7u21-windows-x64.

I'm trying to run a sikuli script by using the command line :
"%SIKULI%"\sikuli-script.cmd -r Myscript.sikuli

Where Myscript.sikuli contains :

from javax.swing import JFrame					 # The JFrame is a top-level window with a title and a border

class Example(JFrame):
    def __init__(self):
			super(Example, self).__init__()
			self.initUI()

    def initUI(self):
			self.setTitle("Simple")
			self.setSize(300, 200)
			self.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE)
			self.setLocationRelativeTo(None)
			self.setVisible(True)

if __name__ == '__main__':
		Example()

The problem is that no GUI appears on the screen and there's no message on the standard output :
[info] Exit code: 0

that's all...

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.