How can I create an exit macro to validate a Text Form Field?

K

Kamran

Hello,
I need to create a macro that will ensure that input into a text form field
is no higher than 99.9.

I've tried using the Maximum Length feature, but I'm unable to use that
properly with decimals because it won't automatically add a "0" decimal when
using the mask "##.0" and it accepts numbers higher than 99.9 if I use the
standard mask "#,##.0". Also, for example, it will turn "333" into "33.3" if
I don't manually type in the decimal.

So what I need is a field that will accept a "XX.X" format and reject
anything higher than that. Thanks in advance.
 
J

Jay Freedman

Hello,
I need to create a macro that will ensure that input into a text form field
is no higher than 99.9.

I've tried using the Maximum Length feature, but I'm unable to use that
properly with decimals because it won't automatically add a "0" decimal when
using the mask "##.0" and it accepts numbers higher than 99.9 if I use the
standard mask "#,##.0". Also, for example, it will turn "333" into "33.3" if
I don't manually type in the decimal.

So what I need is a field that will accept a "XX.X" format and reject
anything higher than that. Thanks in advance.

See http://www.word.mvps.org/FAQs/TblsFldsFms/ValidateFFields.htm.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top