Spell-check within a form

A

Axel

Here is the code I compiled from the various posts:

'Private Sub Project_Summary_AfterUpdate()
' With Me.Project_Summary
' .SetFocus
' If Len(.Text) > 0 Then
' .SelStart = 0: .SelLength = Len(.Text)
' DoCmd.SetWarnings False
' DoCmd.RunCommand acCmdSpelling
' DoCmd.SetWarnings True
' End If
' End With
'End Sub

If I update the field and misspell a word, the spell checking dialog comes
up and selects the misspelled word. However, if I click on "change", I get
the following error:

"The macro or funciton set to the BeforeUpdate or ValidationRule property
for this field is preventing Department Status Database from saving the data
in the field.

*If this is a macro, open the macro in the Macro window and remove the
action that forces a save (for example, GoToControl).
*If the macro includes a SetValue action, set the macro to the AfterUpdate
property of the control instead.
*If this is a function, redefine the function in the Module window."

The form and field are set to allow edits and there are no other macros
associated with that field on the form (no SetValues or GoToControls). The
field is set as a Memo, but I tried changing it to text and get the same
error.

Can anyone help?
 

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