Dudley Dufort Posted June 7, 2010 Posted June 7, 2010 How can I apply validation to a field so that it accepts numbers only. My issue is a decimal point. 123 is a valid entry. 1.23 should fail validation.
Lee Smith Posted June 7, 2010 Posted June 7, 2010 (edited) Why not just use the Filter Function Filter (YourNumberfield ; "0123456789" ) HTH Lee [color:red]p.s. 123 is a valid entry. 1.23 should fail validation. Why? There is a difference in the numbers of 121.77 Edited June 7, 2010 by Guest p.s.
Dudley Dufort Posted June 7, 2010 Author Posted June 7, 2010 Lee Thanks for your interest The field is used to input time in a contest scoring program. Depending upon the application, the entry is either hours and minutes or minutes and seconds. Enabling the scorekeeper to enter whole number allows for faster data entry. No punctuation is necessary to separate the hours from minutes or the minutes from seconds. The entry is converted by a formula (calculation)into all minutes or all seconds. For instance, 115 converts to 75 minutes. I'm trying to invalidate an entry that contains any characters other than numbers. Maybe I don't understand how to use the filter function but it didn't work for me. BTW I see that we're just across the river from each other.
Raybaudi Posted June 7, 2010 Posted June 7, 2010 Try to validate by this calculation: IsEmpty ( Filter ( Self ; KanjiNumeral ( Self ) ) )
Dudley Dufort Posted June 8, 2010 Author Posted June 8, 2010 I tried that. While I don't understand what it does (more reading required) it did cause a validation failure. That's the good news. The bad new is that by choosing "Revert", ALL changes to the record were reverted. Not just the subject (time) field. Dudley
Raybaudi Posted June 8, 2010 Posted June 8, 2010 The bad new is that by choosing "Revert", ALL changes to the record were reverted. Not just the subject (time) field. This is how validation works: all NOT saved data of the record will be lost.
Recommended Posts
This topic is 5341 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