Lakota Posted April 2, 2004 Posted April 2, 2004 Group: I am using FMP 5.0 Unlimited to hadle my database. I am scanning barcodes from client stations throughout the office. These barcodes Contain exactly 7 characters and all start with "F". I need to have FMP validate the data in the field to make sure it starts with the letter "F". Any thoughts on this? I have been looking at validation for text but have come up with nothing useful. Thanks in advance. Lakota FileMaker Version: 5 Platform: Windows 2000
spb Posted April 3, 2004 Posted April 3, 2004 I recently made a barcode inventory scanning database. I set up the scanner so it inputs into a global field, then pauses (for further data entry). When the user hit Enter, the script continued, dumping the global into the real field, and returning the user to the global for the next input. I set this script up to catch scanning errors. After the global was filled with the scan info, I had something like (modified for you): If (Length(g_Input) <> 7 or Left(g_Input) <> "F", Show Message ("Scan was incorrect, try again") SetField (g_Input, "") Go To Field (g_Input) Exit Script Else (do all the stuff required by a successful scan) The awkward aspect is that this requires the user to hit the Enter button (NOT the return key) after every entry. I could not get the scanner to send a preamble (Ctrl-1) then a postamble (Ctrl-2), or I could have broken this into two scripts and avoided the pause and the enter button. Steve Brown
Lakota Posted May 11, 2004 Author Posted May 11, 2004 Steve: What model scanner are you using? Would a carriage return work here? I had to replace scanners for our inventory process and we have made the entire application "hasnd-off" for the users. They scan and run. All other data is related and populates either from system variables or from the database. Just a thought. Lakota
Oldfogey Posted May 12, 2004 Posted May 12, 2004 Try this Loop [scan] Exit Loop If (Length(g_Input) = 7 and Left(g_Input) = "F", Show Message ("Scan was incorrect, try again") SetField (g_Input, "") Go To Field (g_Input) Pause/Resume Script end loop else etc.
Recommended Posts
This topic is 7570 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now