Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

check spelling in 1 record only 9

Status
Not open for further replies.

rene1000

IS-IT--Management
Apr 9, 2002
89
0
0
NL
I have created a button which checks the spelling:

Private Sub button_spelling_Click()
SendKeys "{F7}"
end sub

this works but it starts checking all records in the table instead of only the required current record. Does anyone know how to limit the spell checking to the current record ?

Rene
 
I might put something in the TAG property to keep controls disabled that I always want disabled.

Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
try putting DoCmd.RunCommand acCmdSelectRecord before DoCmd.RunCommand acCmdSpelling
in the code i wrote

Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
This is great, Thanks for your help. In MichaelRed's generalization code, could we not make it even more general, by having it check whatever field the cursor happens to be in when the button is clicked?

 
hmmmmmmmmmmmmmmmmmmmmmmmm ... mmmmmmmmmmmmmm ...

"Seems Like" the only "field" (control?) the cursor could be in would be the "Button"? Since 'cursor' ~~ focus? There aer additional generalizations, but I'm not to sure re this specific one.

Since the control (name / Id) must be unique to the form, one really should not need to address the FORM section, so that is an obvious one. Another POSSABILITY might be to simplify the process of dis-abling the various text boxes by simply disabling ALL and then enabling the specific one (of interest). This would eliminate the logical check within the loop, and thus (aparently) save some execution time (albeit un-noticable at the users level).


I'm sure there are others, for those interested in maximizing performance and / or generalization. On might even consider conscripting the content of the specified control and figuring out a way to do spell check on just the content.




MichaelRed


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top