image thumbnail

setfocus

version 1.0.0.0 (1.97 KB) by Martin Weber
Program to set focus to objects (edit etc) without clicking with the mouse on them.

5.1K Downloads

Updated 26 Aug 2002

translation missing: en-US.gallery.no_license

Set focus to objects. When starting a Matlab GUI it is normally not possible to activate the cursor in an edit object. Before you can type, you'll have to click with the mouse in the edit field. With setfocus it is possible to activate the cursor with program code by passing the object handle to setfocus. setfocus simply simulate a mouseclick in the area of the object.

Cite As

Martin Weber (2022). setfocus (https://www.mathworks.com/matlabcentral/fileexchange/1898-setfocus), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R12.1
Compatible with any release
Platform Compatibility
Windows macOS Linux
Acknowledgements

Inspired: clickfocus, jMouseEmu: Mouse Emulator (v2.3)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!