how to set a default 'enter' on a certain button

后端 未结 6 1861
萌比男神i
萌比男神i 2020-12-01 11:47

There is a textbox on a ContentPage. When the user presses Enter in that textbox I am trying to fire a \'Submit\' button on this ContentPage. I\'d like to fire off that part

6条回答
  •  無奈伤痛
    2020-12-01 12:01

    You can use the DefaultButton property on either a server-side form control or Panel control. In your case, group the controls together in a Panel that should fire off the same button:

    
        ...
        
    
    ....
    
        ...
        
    
    

提交回复
热议问题