By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,483 Members | 1,544 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,483 IT Pros & Developers. It's quick & easy.

rant about focus - has this happened to you

P: n/a
I just spent two hours trying to work out why my procedure wouldn't
allow me to set the focus to a control in a subform. The control is in
a tab control in the subform

My code looked like this

forms!mainform.form!subform.setfocus
forms!mainform.form!subform!control.setfocus

Simple enough I think you would agree.

Nothing I tried would work and now the boss is starting to look at me
funny.
Last resort, I copied the control to the clipboard deleted it and
exited the database. I re-opened the database and ran the procedure,
which it didn't like because now the control doesn't exist. I then
went to design mode and pasted the control back into the form saved it
and ran the procedure again.

Hey presto it now works!

Has anyone seen a problem like this?
Nov 12 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Yes, controls can get corrupted in Access. It happens relatively
frequently. It seems to happen more when renaming or copying controls
(especially between form sections), and it seems to be worse with name
autocorrect turned on, though it can sure still happen with name
autocorrect turned off.

On 13 Oct 2003 23:47:22 -0700, we****@hotmail.com (Michael) wrote:
I just spent two hours trying to work out why my procedure wouldn't
allow me to set the focus to a control in a subform. The control is in
a tab control in the subform

My code looked like this

forms!mainform.form!subform.setfocus
forms!mainform.form!subform!control.setfocus

Simple enough I think you would agree.

Nothing I tried would work and now the boss is starting to look at me
funny.
Last resort, I copied the control to the clipboard deleted it and
exited the database. I re-opened the database and ran the procedure,
which it didn't like because now the control doesn't exist. I then
went to design mode and pasted the control back into the form saved it
and ran the procedure again.

Hey presto it now works!

Has anyone seen a problem like this?


Nov 12 '05 #2

P: n/a
no****@nospam.nospam (Steve Jorgensen) wrote in
<da********************************@4ax.com>:
Yes, controls can get corrupted in Access. It happens relatively
frequently. It seems to happen more when renaming or copying
controls (especially between form sections), and it seems to be
worse with name autocorrect turned on, though it can sure still
happen with name autocorrect turned off.


Does anyone who knows anything about Access development actually
run with Name AutoCorrect on, except accidentally (as happened to
me this week after importing into a new MDB)?

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Nov 12 '05 #3

P: n/a
On Tue, 14 Oct 2003 20:01:49 GMT, dX********@bway.net.invalid (David W.
Fenton) wrote:
no****@nospam.nospam (Steve Jorgensen) wrote in
<da********************************@4ax.com>:
Yes, controls can get corrupted in Access. It happens relatively
frequently. It seems to happen more when renaming or copying
controls (especially between form sections), and it seems to be
worse with name autocorrect turned on, though it can sure still
happen with name autocorrect turned off.


Does anyone who knows anything about Access development actually
run with Name AutoCorrect on, except accidentally (as happened to
me this week after importing into a new MDB)?


Certainly not I. Its about the surest way to mangle your database, and
that's not even talking about the mangling it can do when it's working
properly!

I recommend never using the name autocorrect feature, though I also leave
it on by accident for a while sometimes.
Nov 12 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.