This short video starts with two minutes of trying every widget on the example GUI. Then there is five and a half minutes of showing the callbacks on the widgets.
Hi, i want to know how can i program uitable to be displayed in a separate window after pressing a pushbotton for example?
If i press pushbutton again the context of the table may change also.
kind regards.
I’m building a GUI, so far so good until I tried to make it object oriented. Say that my GUI is in a function called gui.m, and the essential function that is going to be used by gui.m are both dct.m and tmt.m, here lies the problem, both dct.m and tmt.m produces histograms, which uses panels inside gui.m for generating the histograms. How do I deal with the coding, since it will use a handle for the panel inside the gui.m (I don’t use axes for those histograms).
Can you explain further how you got the text to update on button clicks? You update the “handles.textstatus” but above you say to change “edit1_Callback”. I realize the “edit1_Callback” is the callback for the text window, but I am confused about the use of “handles.textstatus”. I cannot figure out how the edit1 text window knows you have clicked a button and therefore updates.
I think the question is “when you leave the editbox, a callback is executed.” The callback on the editbox will update either upon hitting enter *or* losing focus. Clicking on a button is really just losing focus, and has nothing to do with clicking the button.
I think I understood your question, but if I am wrong, please let me know.
Hi I think this is not the right place for ask you this but I don’t know where else is the place, ok, I have I GUI that reads a “.wav” file, and plot it in an axes, and then with another button I can play it, but I am trying to put a vertical line that runs in the plot (axes) while the file is play, do you have any clue? I hope you understand what I am talking about. thanks !!!
I think you should look on the file exchange. Look for things like ’strip chart’. I do not know if there is anything exactly like you want, but there might be something close.
Thanks,
Doug
Leave a Reply
About
Doug Hull is a proud MathWorker who is on a mission to help you with MATLAB.
very comprehensive I like it. This should benefit a lot of new users in MATLAB gui!
Very nice Doug. Lots of people will benefit from this!
Hi, i want to know how can i program uitable to be displayed in a separate window after pressing a pushbotton for example?
If i press pushbutton again the context of the table may change also.
kind regards.
I think lacked explain Edit box’s Callback. Or not?
Something!
Oops. Looks like it got lost in editing. Just modify the
function edit1_Callback(hObject, eventdata, handles)
Doug
Muzaffar,
For two window GUIs, you will want to watch this video.
http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=8616&objectType=FILE
Doug
I’m building a GUI, so far so good until I tried to make it object oriented. Say that my GUI is in a function called gui.m, and the essential function that is going to be used by gui.m are both dct.m and tmt.m, here lies the problem, both dct.m and tmt.m produces histograms, which uses panels inside gui.m for generating the histograms. How do I deal with the coding, since it will use a handle for the panel inside the gui.m (I don’t use axes for those histograms).
What would you suggest me in this situation.
Regards,
Fikri
Fikri,
I am not sure I understand your question. I think you might be better sending the simplified code and the question to support@mathworks.com
Thanks,
Doug
Can you explain further how you got the text to update on button clicks? You update the “handles.textstatus” but above you say to change “edit1_Callback”. I realize the “edit1_Callback” is the callback for the text window, but I am confused about the use of “handles.textstatus”. I cannot figure out how the edit1 text window knows you have clicked a button and therefore updates.
Chris
@chris,
I think the question is “when you leave the editbox, a callback is executed.” The callback on the editbox will update either upon hitting enter *or* losing focus. Clicking on a button is really just losing focus, and has nothing to do with clicking the button.
I think I understood your question, but if I am wrong, please let me know.
Doug
Hi I think this is not the right place for ask you this but I don’t know where else is the place, ok, I have I GUI that reads a “.wav” file, and plot it in an axes, and then with another button I can play it, but I am trying to put a vertical line that runs in the plot (axes) while the file is play, do you have any clue? I hope you understand what I am talking about. thanks !!!
@mario,
I think you should look on the file exchange. Look for things like ’strip chart’. I do not know if there is anything exactly like you want, but there might be something close.
Thanks,
Doug