Results 1 to 4 of 4

Thread: How to set Default to Button

  1. #1

    Thread Starter
    Lively Member fifo's Avatar
    Join Date
    Dec 2005
    Location
    HaiPhong, Vietnam
    Posts
    77

    How to set Default to Button

    Hi,

    I made a form with a Button and 2 TextBox. When you press Enter in whatever TextBox, Button will be press.

    I mean making a default Button in form?

    Show me how?
    !Have fun!

  2. #2
    PowerPoster gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: How to set Default to Button

    Hello,

    When you select your form (in design view), in the Properties Window, find the AcceptButton Property, and in the drop down menu, select the button that you want to make your default.

    You can also set the default cancel button as well using the CancelButton Property.

    Hope this helps!

    Gary

  3. #3
    Frenzied Member
    Join Date
    Mar 2006
    Location
    Pennsylvania
    Posts
    1,069

    Re: How to set Default to Button

    u could also do something like.. i think it was..

    Button1.PerformClick()

    or something like that

  4. #4

    Thread Starter
    Lively Member fifo's Avatar
    Join Date
    Dec 2005
    Location
    HaiPhong, Vietnam
    Posts
    77

    Re: How to set Default to Button

    Nice, useful.

    Thanks all.
    !Have fun!

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