"Enter" key function to assign variable in GUI

14 visualizaciones (últimos 30 días)
Emre Can Ertekin
Emre Can Ertekin el 19 de Oct. de 2018
Comentada: Kevin Chng el 19 de Oct. de 2018
I have a problem in adding enter key to my GUI, while taking variable from the user. How can i write a function for enter key?
  3 comentarios
Emre Can Ertekin
Emre Can Ertekin el 19 de Oct. de 2018
For example in my gui i have a amplitude of the signal in edittext box, i want the when user enter the value of amplitude end press 'Enter button in keyboard' gui should assign the valur and change the axes.
Kevin Chng
Kevin Chng el 19 de Oct. de 2018
App designer?

Iniciar sesión para comentar.

Respuestas (1)

Walter Roberson
Walter Roberson el 19 de Oct. de 2018
Use the Callback property of the uicontrol. It will be run when the user presses return after selecting the control, or if the user makes a change to the content of the edit field and then clicks somewhere outside the control.

Categorías

Más información sobre Interactive Control and Callbacks en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by