Validating a character string pre db assign

Hi everyone, simple question I hope.

I have a character fill-in widget that has a format defined of '9999-9999'.

If I enter '1234- 567' and then try and save it I get the a Progress error message "Character at position 6 must be a digit".

Is there a function I can use to validate the string pre-save or failing that can anyone suggest a nice and simple validation routine?

Thanks in advance.
Chris
 
Sorry cancel this request. I was trying to apply this format to an existing value which was '1234- 567' and thus invalid.

Of course one cannot enter a space in the character string format '9999-9999'.

Cheers
Chris
 
Back
Top