Keep the variable of ediTtext if you don't change it
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Hello, I want to do a GUI that have 4 editText, 1 pushbutton and 1 table. I want to put the info of the editText in the table. When I put the values in the editText and I push the button, it puts in the table. If I don't change anything and I push the button, the gui don't catch the values of the editText. If I change the values all the time I don't have this problem.
- Example: I put the values 4 5 6 7 into the text box
- I hit the button (the values get put into the table)
- I hit the button without changing the values (Here is my problem!)
0 comentarios
Respuestas (1)
Image Analyst
el 2 de Dic. de 2017
What is the code in the callback for the push button? If it extracts the edit text string, and parses it, and puts it into the table, it will work regardless if the text has been changed or not. It simply works on the current string in the edit text box.
2 comentarios
Image Analyst
el 2 de Dic. de 2017
set a breakpoint in that function. Does it step on the same lines of code in the two cases? What are the values of the variables? Just do normal debugging and you should be able to figure it out.
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!