user interface - How do I mimic a button click in matlab -
how mimic button click in matlab?
simply excecuting callback function doesn't work since within callback uses gcbo command , cannot alter excecuting function. furthermore not shadow gcbo obvious reasons.
in case matters solution works on matlab r2012a.
you can try calling java.awt.robot class, example.
robot = java.awt.robot; pause(2) % wait time robot.keypress (java.awt.event.keyevent.vk_enter); % press "enter" key robot.keyrelease (java.awt.event.keyevent.vk_enter); % release "enter" key read more gui automation using robot here...
i'm not sure work on matlab r2012a, on later versions.
Comments
Post a Comment