i want to run the a m-file program using gui pushbutton,,,,
1 view (last 30 days)
Show older comments
i want to run the a m-file program using gui pushbutton,,,the output of that m-file should be displayed in edit box.....tell me the matlab code to create it.....
1 Comment
Jan
on 23 Apr 2014
Dear Kiran, neither dots nor commas look better, when they appear in a troop. "Tell me" is a command and you have more success in this forum if you decorate a request with e "please".
Please show us, what you have tried so far and explain the occurring problems. Then clarify what "the output" means, because this could mean nearly every thing.
Answers (1)
Jan
on 23 Apr 2014
function myDialog
figure;
outputH = uicontrol('style', 'edit', 'Position', [120, 10, 100, 20]);
uicontrol('style', 'pushbutton', 'Position', [10, 10, 100, 20], ...
'String', 'Start', ...
'Callback', {@StartBtnCallback, outputH});
function StartBtnCallback(ObjectH, EventData, outputH)
result = YourFunction;
% Assuming that the replied value is a string, otherwise use SPRINTF...
set(outputH, 'String', result);
See Also
Categories
Find more on Numerical Integration and Differential Equations in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!