Run time error 7768 on form

R

Randy

This code runs whenever a change occurs on a previous record. It usually
works fine. but sometime I get a runtime error 7768 when a change is made
to a combo box. It debugs to the following code. Whats the probelm?
Thanks...Randy

Private Sub Form_BeforeUpdate(Cancel As Integer)
Dim stDocName As String
DoCmd.SetWarnings False

If Not Me.NewRecord Then 'Save any edits first.
Me.Dirty = True
stDocName = "AppendCorrections"
DoCmd.OpenQuery stDocName, acNormal, acEdit
End If
DoCmd.SetWarnings True
End Sub
 
R

Randy

Whoops, I forgot the error message. Here it is." In order to change data
through this form, the focus must be in a bound field that can be modified"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top