The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: How to get rid of a long delay after button press in GUI
Replies: 0  

Advanced Search

Back to Topic List Back to Topic List  

Posts: 16
Registered: 10/31/12
How to get rid of a long delay after button press in GUI
Posted: Nov 6, 2012 1:39 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

I have several buttons on a gui, each with its own specialized callback. The GUI responds quickly to most of them. However, if one of them (next button) is the first thing pressed, the GUI takes a long time (several seconds) to respond. I put a disp('In next button callback'); at the top of the callback just to see when it enters and this output doesn't even show up for a while. Strangely, this is only true for this button and not for the others, even though they look to be set the same way.

myHandles.nextEmbryo_button=uicontrol(myHandles.figHandle,'Style','pushbutton', 'String','Next Embryo','Units','normalized','Position',[600 10 100 30]./figWH,'Callback',@nextEmbryo_button_ButtonDownFcn,'Tag','nextEmbryo_button');

myHandles.downSlice_button=uicontrol(myHandles.figHandle,'Style','pushbutton', 'BackgroundColor','b','String','-','Units','normalized','Position',[0 430 40 40]./figWH,'Callback',{@shiftSliceView_button_ButtonDownFcn,'-'},'Tag','downSlice_button');

Any suggestions on what could be wrong or steps I should take to troubleshoot?


Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.