LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Login

Hai,


         In a Login screen , when the user enters the name  if they enter ,./;'":<>?[]}{ these kind of characters i want to stop them. Give an idea          
0 Kudos
Message 1 of 4
(2,588 Views)
Hi LabView5,

use an event structure with event "key press" (or similar). You will get an ASCII code (or kind of "key code") and you can filter those keys...

Filtering can be done like this:



Message Edited by GerdW on 01-21-2008 01:03 PM
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 4
(2,584 Views)
Sorry i cannot ale to understand could u explain mee breifly
0 Kudos
Message 3 of 4
(2,577 Views)
Hi LabView5,

which LV version do you use?
Have you ever used the event structure before? Have you looked at the examples for the event structure?

You can react on events (like: value change, mouse move, key press) using this structure! So when the user presses any of the "forbidden" keys you can react to this input.

Btw. you can set your string input to "update while typing" allowing you to poll the string control and search for "forbidden" chars. But the event structure is more efficient here...
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 4
(2,573 Views)