CharlieT302
Instructor
Hello Everyone,
I have a form with several text boxes within it. Only two of which need to be checked for spelling errors. I am attaching code to a button on the form so that the user can check the spelling when desired.
I have programmatically selected the record prior to running the spell checker so as to only check the current record. This works fin. However, once initiated, the spell checker insists on checking each text box within the record rather than that which I specify.
Basically, I need to check specific text boxes within the current record only. See current code below.
Spell_Comments_Val:
If Trim(Me.Staff_Comments & "") = "" Then
GoTo exit_sub
Else
Spell_Comments:
Me.Staff_Comments.SetFocus
DoCmd.RunCommand acCmdSelectRecord
DoCmd.RunCommand acCmdSpelling
GoTo exit_sub
End If
I am sure that the "SelectRecord" command is negating the .SetFocus command. How else can I accomplish this?
I have a form with several text boxes within it. Only two of which need to be checked for spelling errors. I am attaching code to a button on the form so that the user can check the spelling when desired.
I have programmatically selected the record prior to running the spell checker so as to only check the current record. This works fin. However, once initiated, the spell checker insists on checking each text box within the record rather than that which I specify.
Basically, I need to check specific text boxes within the current record only. See current code below.
Spell_Comments_Val:
If Trim(Me.Staff_Comments & "") = "" Then
GoTo exit_sub
Else
Spell_Comments:
Me.Staff_Comments.SetFocus
DoCmd.RunCommand acCmdSelectRecord
DoCmd.RunCommand acCmdSpelling
GoTo exit_sub
End If
I am sure that the "SelectRecord" command is negating the .SetFocus command. How else can I accomplish this?