aziz rasul
Active member
- Local time
- Today, 14:33
- Joined
- Jun 26, 2000
- Messages
- 1,935
When I close a form and I have created a duplicate primary key, I get the general message telling me that 'I can't save the record at this time', blah, blah. I DON'T GET AN ERROR NUMBER.
I have a message box which I have created in Access which I use when an error appears e.g.
How can I display "frmTimedMessageBox" instead of obtaining the Access error dialog box?
I have a message box which I have created in Access which I use when an error appears e.g.
Code:
If Err = 3022 Then
DoCmd.OpenForm "frmTimedMessageBox"
Forms!frmTimedMessageBox.TimerInterval = 3500
Forms![frmTimedMessageBox]!lblMessage.Caption = "A record already exists with the same primary key 'Distributor Ref' value."
Exit Sub
End If
How can I display "frmTimedMessageBox" instead of obtaining the Access error dialog box?