Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2004
    Swindon, UK

    Unanswered: GotFocus & LostFocus code


    I have a form with about 17 Textboxes and 12 Combi's, behind each one i am running GotFocus & LostFocus code, the code is exactly the same for all. Is there a way i can call this, without having to put it behind each and every textbox???

    Thanx in advance...
    "Computers make it easier to do a lot of things, but most of the things they make it easier to do don't need to be done."

  2. #2
    Join Date
    Feb 2004
    In the code module you should have two functions:
    Private Function ActiveControl_GotFocus()
        your code here
    End Function
    Private Function ActiveControl_LostFocus()
        your code here
    End Function
    Then, for each of the controls, set the OnGotFocus property to:


    ...and the OnLostFocus property to


Posting Permissions

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