LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Enter key

How to detect if ENTER key pressed at the and of string in a textbox.
0 Kudos
Message 1 of 3
(2,525 Views)
Use "String to byte array" vi. Each byte in this array
represents ASCII code of symbol in string.
If Enter key pressed at the end of string you will
get ASCII code 10 in last byte of array.
0 Kudos
Message 2 of 3
(2,525 Views)
If you want to detect when the user hits the Enter key when he is done with string edition, use its key focus property.
Set the string to "Limit to Single Line". When the user is currently editing the string, the key focus is True. After Enter is hit, the keyfocus toggles to False. You just have to detect this True/False transition of the property.


LabVIEW, C'est LabVIEW

0 Kudos
Message 3 of 3
(2,525 Views)