surfdragon
Registered User.
- Local time
- Today, 02:09
- Joined
- Jan 26, 2016
- Messages
- 15
Hi, I am new to databases and VB so please be gentle with me !!! Sorry for the long question.....
I have created a database with a form and all works as advertised - great.
BUT, when i go to the next record it leaves the previous selection from the combo boxes in the new record?????
I found some coding which should allow me to clear the form when new record is selected, but I can't get it to work and I dont understand VB so am trying to learn on thejob. Is this code the best way of dealing with this or do I need a different solution
Code attached:
Private Sub Form_Current()
On Error Go to ErrorHandler
Me![cboname of box]= Null
ErrorHandlerExit
Exit Sub
ErrorHandler:
MsgBox "Error No: " & Err.Number &": Description: " & Err.Description
Resume ErrorHandlerExit
End Sub
Any help would be greatly received
I have created a database with a form and all works as advertised - great.
BUT, when i go to the next record it leaves the previous selection from the combo boxes in the new record?????
I found some coding which should allow me to clear the form when new record is selected, but I can't get it to work and I dont understand VB so am trying to learn on thejob. Is this code the best way of dealing with this or do I need a different solution
Code attached:
Private Sub Form_Current()
On Error Go to ErrorHandler
Me![cboname of box]= Null
ErrorHandlerExit
Exit Sub
ErrorHandler:
MsgBox "Error No: " & Err.Number &": Description: " & Err.Description
Resume ErrorHandlerExit
End Sub
Any help would be greatly received