01-15-2025, 03:58 PM
(This post was last modified: 01-15-2025, 04:15 PM by jrmrhrb00.
Edit Reason: Edit
)
LitDev,
This snippet works now. I agree. "Strange"
GW.Show()
While key <> "Return"
key = GraphicsWindow.Lastkey
EndWhile
TextWindow.WriteLine("H")
I am pretty sure in my program that the LDTextWindow.SendKey doesn't reset GraphicsWindow.LastKey. I put a TW.Writeline(GraphicsWindow.LastKey in front of the wait loop and for the second run of the program it shows the "Return" key. It should show the space key, but doesn't.
Would it be possible in the extension under utilities to add a reset function to GraphicsWindow.LastKey?
JR
Here is what I have in the actual program:
'TW.WriteLine(GraphicsWindow.LastKey)
While key <> "Return"
key = GraphicsWindow.Lastkey
EndWhile
Program.Delay(10)
LDTextWindow.SendKey(GraphicsWindow.Title,"Space") 'Send a Space key so initially LastKey is not Return
Program.Delay(10)
key=GraphicsWindow.LastKey
TW.WriteLine(key)
It never shows "Space as the last key. Only "Return"
This snippet works now. I agree. "Strange"
GW.Show()
While key <> "Return"
key = GraphicsWindow.Lastkey
EndWhile
TextWindow.WriteLine("H")
I am pretty sure in my program that the LDTextWindow.SendKey doesn't reset GraphicsWindow.LastKey. I put a TW.Writeline(GraphicsWindow.LastKey in front of the wait loop and for the second run of the program it shows the "Return" key. It should show the space key, but doesn't.
Would it be possible in the extension under utilities to add a reset function to GraphicsWindow.LastKey?
JR
Here is what I have in the actual program:
'TW.WriteLine(GraphicsWindow.LastKey)
While key <> "Return"
key = GraphicsWindow.Lastkey
EndWhile
Program.Delay(10)
LDTextWindow.SendKey(GraphicsWindow.Title,"Space") 'Send a Space key so initially LastKey is not Return
Program.Delay(10)
key=GraphicsWindow.LastKey
TW.WriteLine(key)
It never shows "Space as the last key. Only "Return"