Connecting Tech Pros Worldwide Help | Site Map

How to spell check one field, in one record

  #1  
Old July 1st, 2008, 02:15 PM
Lynx101
Guest
 
Posts: n/a
I've got the following code to work, but the problem is that it is
check all fields on every record. Is there a way to make this work on
one particular field AND only the current record?


Dim strSpell
strSpell = YOURFIELDNAME
If IsNull(Len(strSpell)) Or Len(strSpell) = 0 Then
Exit Sub
End If
With YOURFIELDNAME
.SetFocus
.SelStart = 0
.SelLength = Len(strSpell)
End With
DoCmd.SetWarnings False
DoCmd.RunCommand acCmdSpelling
DoCmd.SetWarnings True

Many thanks
  #2  
Old July 1st, 2008, 03:15 PM
Lynx101
Guest
 
Posts: n/a

re: How to spell check one field, in one record


Resolve by using the following adaptation of the above code:


If Len(Me.YOURFIELDNAME & vbNullString) 0 Then
With me.YOURFIELDNAME
..SetFocus
..SelStart = 0
..SelLength = Len(.Text)
End With
DoCmd.RunCommand acCmdSpelling
end if
Closed Thread


Similar Threads
Thread Thread Starter Forum Replies Last Post
Controlling Spell Checker Neil answers 6 April 17th, 2007 09:35 AM
MS Access Spell Check jamesnkk answers 4 December 30th, 2006 04:12 PM
What is Expressiveness in a Computer Language Xah Lee answers 669 July 22nd, 2006 04:45 PM
Invalid procedure call in query - why!??! Martin Lacoste answers 6 November 13th, 2005 02:55 AM