Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

vba code validation rules

Forum home » Delegate support and help forum » Microsoft Access Training and help » Vba code for validation rules to prevent users from selecting th

Vba code for validation rules to prevent users from selecting th

ResolvedVersion 2007

Astley has attended:
Access Advanced course

Vba code for validation rules to prevent users from selecting th

Hi, I am developing an Access 2007 database and would like to write code for a validation for two combo boxes on a form. One combo box has a drop down list of starting times and the other combo box has a list of ending times. I entered a validation rule and text message on a form, but whenever I selct a time a pop up message keeps displaing and prevent the user from making a selection, so they have to close down the database and re-open it, as you can imagine this can be frustrating for the user to do. What I would like to do is prevent the user from selecting either an end time that is earlier than a start time, and a start time that is later than an end time. Is this possible to do? If so, how can this be done? If you have any examples that would be very helpful. Thanks for your solutions. I look forward to your response.


Astley

RE: vba code for validation rules to prevent users from selectin

Hi Astley

I am sorry that we have not been able to get back to you as soon as we would have liked. We will be in touch shortly to progress your question.

Thank you for your patience.

Kind regards,

Andrew

Access tip:

Splittng a database

Split your database into two (at least).

Keep all of your code, forms, reports, etc. in one 'code' database and all of your tables in another 'data' database which is then linked to the 'code' database.

This makes modifications, updates and back-ups that much easier and allows you to work on a new version of your 'code' database without affecting existing users. It also makes it easier should you wish to convert a single user databases into a multi-user networked version.

View all Access hints and tips

Connect with us:

0207 987 3777

Call for assistance

Request Callback

We will call you back

Server loaded in 0.1 secs.