integrating a gui with a program
古いコメントを表示
function varargout = interface(varargin)
function interface_OpeningFcn(hObject, eventdata, handles, varargin)
function varargout = interface_OutputFcn(hObject, eventdata, handles)
function Vel_Callback(vel, eventdata, handles)
function Vel_CreateFcn(vel, eventdata, handles)
this is the gui structure I have created, inside each function there is more code (some of them automatically created by MatLab) the idea is that I want to select a value of velocity from a pop up menu and I want to use the value chosen in a big program with tons of calculations where I must introduce the program to have the results of the program in the workspace
the idea a what to develop is 1.introduce some values with pop-up menus transfer the values to the workspace and there use them as constant for the program I have developed in other script
2. used the values in some calculation
I know is tricky but I have to programs a GUI and m file and I don't know how I can integrate them together
採用された回答
その他の回答 (1 件)
Patrick Brown
2017 年 1 月 28 日
0 投票
1 件のコメント
Jan
2017 年 1 月 28 日
@Patrick: guidata(H, Data) uses setappdata internally to store the variable "Data" in the 'ApplicationData' property of the GUI object with the handle H. To obtain the stored data use: Data = guidata(H), which calls getappdata internally. For further explanations and examples read doc guidata.
カテゴリ
ヘルプ センター および File Exchange で App Building についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!