To download NI software, including the products shown below, visit ni.com/downloads.
Overview
This example uses an event structure to filter out certain characters.
Description
It only allow A-z and have a limited number of characters we allow in the input. This allows you to make sure that the data you entered from a control is controlled. It also disallows copy/pasting into the control.
Requirements
Steps to Implement or Execute Code
Additional Information or References
VI Block Diagram
**This document has been updated to meet the current required format for the NI Code Exchange.**
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.
Thanks for the code Dylan! Found it really useful.
Few points for other people looking at it. Numbers are not allowed characters (as stated above), you need to add the range of 48 to 57 to the case that is wired directly through. Also if you are trying to recreate this from scratch in your own application, remember to enable "Update Value while Typing" on the string control. If you don't do this then the maximum allowable characters will only work if you click away from the dialog box after entering each character.
Only checked the above in the 2011 version.