Print Page | Close Window

URGENT! - Validation in Access 2000

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Database Discussion
Forum Description: Discussion and chat on database related topics.
URL: https://forums.webwiz.net/forum_posts.asp?TID=755
Printed Date: 28 March 2026 at 8:51pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: URGENT! - Validation in Access 2000
Posted By: hockenpj
Subject: URGENT! - Validation in Access 2000
Date Posted: 05 March 2003 at 3:43pm

Hi,

I want to add validation to an Access database.  I know that this is done when creating a table.

What I want to do is to define a minimum length of text that needs to be entered in a First Name field.

Do I need to add something in the Input Mask?

Please Help Me!




Replies:
Posted By: michael
Date Posted: 05 March 2003 at 9:12pm
Well you could just put a validation rule into the fieldname so something like Len([fieldname])>=5   but I don't know if that is a good idea. I would do that either in jscript on the form page or do some asp validation like <%If len(name) < 5 THEN GOTOHELL()%> or both to be secure. The problem with doing that in Access only is that the db would throw an error updating or inserting a field and your page would not render. This means you would have to write an error handler that catches exactly that to let the user know what he did wrong.


Posted By: hockenpj
Date Posted: 06 March 2003 at 3:27am

Michael,

Thank you so much for your prompt reply.

Len([fieldname])>=5 works just fine for me.

You don't know how long I spent trying to work out the Len bit!

About the Jscirpt and ASP validation there is no need.  It is not for an onine apllication.

It is for my AS ICT OCR Set Task - you rember the other post?

Thank you so much!



Posted By: hockenpj
Date Posted: 06 March 2003 at 9:44am

Michael,

Can you suggest any similar validation for Access 2000, but this time it is to validate an e-mail address eg. has to have an @ symbol etc



Posted By: Bunce
Date Posted: 07 March 2003 at 1:18am
Search Access Help for Input Masks.

-------------
There have been many, many posts made throughout the world...
This was one of them.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net