Jump to content

This topic is 8220 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hello, I have a question. Is there any way to either have a field validated by a script, or else to have the normal validation trigger a script if the field is invalid?

Here's the situation:

My users enter a phone number into a field, it is then validated to make sure the dashes are in the right place, and the area code exists in a seperate DB of valid area codes. Now, if the dashes aren't there, it should tell them to reformat the number, and not let them have the data they entered. If the Area code is not recognized, it should give them a choice, to reenter it, to add the area code to the dictionary or override the problem.

Thoughts?

Posted

Simplest way is to split the number into three fields -- area code, prefix and ... well, I don't know what they call the last four numbers. The area code field can validate against the list, and the other two fields can validate against a range.

Posted

But that still doesn't solve part of the problem. If the area code is found invalid, they basically need a dialog with three buttons, and a script to process those three choices. If A - Revert Field, If B - Allow Value, If C - Create new record in table of valid area codes with a value equal to area code. TYhanks for that much though...

This topic is 8220 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.