Results 1 to 10 of 10

Thread: Updown control buddy-ed

  1. #1

    Thread Starter
    PowerPoster JPnyc's Avatar
    Join Date
    Oct 2002
    Location
    Manhattan
    Posts
    3,015

    Updown control buddy-ed

    I have what I think is a bizarre problem. I have an updown control buddied to a bound textbox. When I type to change the value in the textbox, it updates the DB field just fine. However, when I use the updown control to change the value, it changes the visible value in the box, but does NOT update the field in the DB. This is confusing the he!! out of me. Help?

  2. #2

  3. #3

    Thread Starter
    PowerPoster JPnyc's Avatar
    Join Date
    Oct 2002
    Location
    Manhattan
    Posts
    3,015
    The update event is triggered by another click event of another control. But when I use the updown to change the value in the textbox, it doesn't update the DB. If I type into the textbox to change the value, then it does update.

  4. #4

  5. #5

    Thread Starter
    PowerPoster JPnyc's Avatar
    Join Date
    Oct 2002
    Location
    Manhattan
    Posts
    3,015
    No, it's a bound control. The only code on the form is the ok(update) and cancel control buttons. The updown is buddied to the textbox.

  6. #6

  7. #7

    Thread Starter
    PowerPoster JPnyc's Avatar
    Join Date
    Oct 2002
    Location
    Manhattan
    Posts
    3,015
    I don't know what good that would do. Everything updates fine, including the textbox, except when the value is changed with the updown control. If I type in the textbox and click OK it updates to the new value. The updown control appears to change the text, but it's not getting through to the recordset. Maybe I should abandon the buddy method and code it.

  8. #8

  9. #9

    Thread Starter
    PowerPoster JPnyc's Avatar
    Join Date
    Oct 2002
    Location
    Manhattan
    Posts
    3,015
    But the controls update just fine. All the textboxes update the DB except when the updown control is used to change the value in the txtbox. If I type in the change it updates. that's why it's baffling. I should just code the scrolling I think. BTW, I'd be happy to attach the project, but it's on my laptop, which is tough to get online with my setup here. I'll be able to do it tomorrow, if I don't solve it by then, and would appreciate any help.

  10. #10

    Thread Starter
    PowerPoster JPnyc's Avatar
    Join Date
    Oct 2002
    Location
    Manhattan
    Posts
    3,015
    This has been resolved. Bound controls only update when they have focus. Setting the focus to the textbox, in the change event of the updown control, solved the problem.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width