Results 1 to 2 of 2

Thread: Disable command button

  1. #1

    Thread Starter
    Frenzied Member aikidokid's Avatar
    Join Date
    Aug 2002
    Location
    Bristol, UK
    Posts
    1,968

    Disable command button

    I want to disable a command button if the user clicks on any part of the form or any control on the form, other than this one command button. Do I have to trap the mouse down, maybe with an API, and see where it is and if it is not above the command button, then disable it?
    If not this way, how can I do this?
    Thanks

    aikidokid

  2. #2
    Addicted Member
    Join Date
    Nov 2001
    Location
    San Diego, CA
    Posts
    159
    Depending on which way you want to go, you can use several different methods such as Keypress, Keydown, MouseOver, etc.

    However, you have to use the method for each instance that will disable the command button. For example:

    Private sub Form_Keypress( xxxxx)
    me.CommandButton.enabled = False
    end sub
    ttfn
    Kicker

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