O'Reilly logo

Mastering NetBeans by David Salter

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Macro recording and playback

In the previous sections, we've seen how to quickly insert stock code into a source code file via both code templates and dragging and dropping palette items. The next technique for modifying or inserting new code into a file that we will look at is macros.

Within NetBeans, macros allow us to capture screen recording and then assign the recording to a keyboard shortcut, which, when selected, will playback the recorded keystrokes. This can be very useful for performing automated tasks against a source code file or indeed, any editable file.

A basic installation of NetBeans is supplied with three existing macros. To view the macros that are stored within NetBeans, access the NetBeans Options menu (select Tools and then ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required