Sub AppStart (Form1 As Form, Args() As String)
MainForm = Form1
'MainForm.RootPane.LoadLayout("Layout1") 'Load the layout file.
MainForm.Show
textarea1.Initialize("")
MainForm.RootPane.AddNode(textarea1,10,10,100,100)
Dim robot1 As JavaObject
Dim jo1 As JavaObject
Dim keycodes As JavaObject
keycodes.InitializeStatic("javafx.scene.input.KeyCode")
jo1.InitializeStatic("com.sun.glass.ui.Application")
robot1 = jo1.RunMethodJO("GetApplication",Null).RunMethodJO("createRobot",Null)
textarea1.RequestFocus
' you have to think how you would type the characters
robot1.RunMethod("keyPress", Array(keycodes.GetField("SHIFT")))
robot1.RunMethod("keyPress", Array(keycodes.GetField("BACK_QUOTE")))
robot1.RunMethod("keyRelease", Array(keycodes.GetField("BACK_QUOTE")))
robot1.RunMethod("keyRelease", Array(keycodes.GetField("SHIFT")))
robot1.RunMethod("keyPress", Array(keycodes.GetField("A")))
robot1.RunMethod("keyRelease", Array(keycodes.GetField("A")))
End Sub