×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Advice Needed: CheckBox control/field not updating last selected
2

Advice Needed: CheckBox control/field not updating last selected

Advice Needed: CheckBox control/field not updating last selected

(OP)
I've got this limping along but you may know a better way.

Senario:
I have a continuous form with only one active control in the detail section, a CheckBox to select documents for further processing. Access 2K.

Problem:
The last record selected via a CheckBox control click is not updated until I move off of the selected record or I requery the whole form.

Here are a few things that I've tried.
1) Sub MyCheckBox_AfterUpdate()
    Me.AnotherControlInHeaderSection.SetFocus
End Sub
2) Sub MyCheckBox_AfterUpdate()
    Me.DummyControlInDetailSection.SetFocus
End Sub
3) Moving to anther record programmatically with DoCmd.GotoRecord... this works except if there is only one record in the list.
4) Me.Requery... This actually works but there's got to be a more direct way.

If you've got some ideas about how to do it better or why Access can't do it better, chime in.

rafe

RE: Advice Needed: CheckBox control/field not updating last selected

Try saving the record.

DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70


DougP, MCP
 dposton@universal1.com
 
 Ask me how Bar-codes can help you be more productive.

RE: Advice Needed: CheckBox control/field not updating last selected

(OP)
Like a charm!

Thank you!

RE: Advice Needed: CheckBox control/field not updating last selected

Earlier posts were helpful (as in the need to save record)

for Access97 and 2000 use

RunCommand acCmdSaveRecord

instead

Ed

RE: Advice Needed: CheckBox control/field not updating last selected

(OP)
Ed,

I like the change. A more compact notation though functionally the same. I've made the replacement.

'DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70

DoCmd.RunCommand acCmdSaveRecord

Thank you both.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login


Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close