Hi all,
Is there a way to change the pop up message for someone trying to enter duplicate information? Right now it a long message that is not very easy to understand for non Access users.
Hi all,
Is there a way to change the pop up message for someone trying to enter duplicate information? Right now it a long message that is not very easy to understand for non Access users.
What information are they entering?
Deal with the user input before Access does. Use BeforeUpdate event with code to check database for possible duplicate and if found cancel the user entry, give them a message 'already in database' and return them to the form.
Another approach is to give users valid choices from combobox list.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
The information would be invoice number (we obviously don't want that to duplicate ). I have an embedded Macro setup on "Before Update". Action is "MsgBox" with an argument message "Error duplicate invoice number". But this message is popping up on every invoice number regardless if it's a duplicate. Not sure what I'm doing wrong....
I don't use embedded macros, only vba.
The macro doesn't include code to search for the duplicate and also need an If Then conditional statement. In VBA, something like:
If Not IsNull(DLookup("SerialNumber", "tablename", "SerialNumer='" & Forms!formname!textboxname & "'")) Then
MsgBox "already in database"
Cancel = True
End If
Could attach project for analysis.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.