Allow Only One Record Entry on Form

CadMonkey

Misplaced But Useful
Local time
Today, 00:07
Joined
May 19, 2004
Messages
47
Hi,

This post has been asked but never resolved so I'm trying again??

In order to ensure that only one record can be added on a form, I am wanting to diasble moving onto another new record.

I've tried setting the cycle property and have deleted the navigation buttons etc. But using the wheel mouse and page down still allows people to move onto another new record.

Can anyone help??

Thankyou,

Simon
 
Do a search on disabling the mouse wheel.
 
Mile-O-Phile said:
Do a search on disabling the mouse wheel.

No good really- what about page down and page up keys? I just wandered if there was an overall way to allow only one record entry, it seems there should be??

Thanks
 
WHy would you opnly store one entry anyway?
 
Mile-O-Phile said:
WHy would you opnly store one entry anyway?

I am probably Not Using Access in the best way I know but it's too make things simpler. I'm using a switchboard with a different form to add a record, another one to view old ones. I'm going for mega user friendliness, which is a hard thing to do because there's so many possibilities, wrong kep presses, misplaced curisosity lurking amongst users.

With only one record entry things are a bit tighter.
 
What about a block in the BeforeUpdate of the form?

ie.

Code:
Option Explicit
Option Compare Database

Dim booLockForm As Boolean

Private Sub Form_BeforeUpate(Cancel As Integer)
    If Not booLockForm Then Cancel = True
End Sub

Until you specifically set booLockForm within the code then it can't switch to any other record.
 
CadMonkey said:
But using the wheel mouse and page down still allows people to move onto another new record.
Check this link out and try the sample I posted for you can do exactly what you want to prevent if you follow my method... A better mouse trap?
 

Users who are viewing this thread

Back
Top Bottom