O'Reilly logo

Learning MIT App Inventor: A Hands-On Guide to Building Your Own Android Apps by Mark Sherman, Derek Walter

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

Types of Procedures

The Procedures drawer has two Procedures blocks: do and result. You can find them by clicking the Procedures block in the drawer (see Figure 5.2).

Image

Figure 5.2 The do and result procedures.

The do procedure collects a sequence of blocks into one group. This same collection of blocks can then be called later, which means the blocks in this do group will be run in order every time you use the procedure. When you give the set of blocks a custom name, that set appears below the do and result options in the drawer.

The result block has a differently shaped slot. This kind of procedure provides a result value when it is done. When ...

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