button to activate textboxes in GUI
Mostrar comentarios más antiguos
Hi: How can i make it so that when i click on a button, it gathers information in textbox(s)? I have get(hObject, 'string') for my textbox, but how do i link this to another button? Thanks
Respuesta aceptada
Más respuestas (1)
Grzegorz Knor
el 20 de Sept. de 2011
You have to create callback function:
2 comentarios
Andy
el 20 de Sept. de 2011
Grzegorz Knor
el 20 de Sept. de 2011
function test
uicontrol('Style','pushbutton','String','read','callback',@pb_clbck)
h = uicontrol('Style','Edit','String','write me!',...
'Units','normalized','Position',[.4 .45 .2 .1]);
function pb_clbck(src,evnt)
disp(get(h,'String'))
end
end
Categorías
Más información sobre Characters and Strings en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!