Is there a command that will refocus the active window back to the command window in Matlab's GUI?
12 次查看(过去 30 天)
显示 更早的评论
I am trying to use a script (script A) that prints a letter to the active window every 2 seconds to test the timing of one of my scripts (script B). I have just noticed that when I run script B on a second monitor, so I can see the Psychtoolbox window and the Matlab window, script A finally works when I click on the command window after the Psychtoolbox window flips.
It won't be a perfect fix but if I can find a command (or a functions I can write to mimic this) it should solve the problem for now. I have quizzed the Psychtoolbox boards, as well, in case I can't find an answer here.
I have also found a bunch of questions on this board that are similar to the one I am asking, but they all regard focus shifts from a figure created by MatLab. I am going to try the options given in those answers but as I am not dealing with a figure I believe it won't fix the problem.
1 个评论
Jan
2019-7-30
Please mention, what "prints a letter to the active window" exactly means. How do you "run a script on a 2nd monitor"?! Monitors cannot run scripts.What ist "the Matlab window"? What does "the Psychtoolbox window flips" mean?
I do not understand, what you want to achieve, what are you doing currently and which problem you have.
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!