O'Reilly logo

App Inventor for Android: Build Your Own Apps — No Experience Required! by Jason Tyler

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

Blocks and Component Reference

This Blocks and Component Reference explains App Inventor’s important blocks and components and those not used or explained in the main projects throughout this book. This is not a comprehensive reference. Refer to the index to discover where you can find more information on any component not referenced here. App Inventor is growing and improving all the time. Be sure and check out the online documentation for App Inventor at http://appinventor.googlelabs.com/learn/reference/index.html.

Built-In Blocks

All of the drawers for the built-in App Inventor blocks are located on the Built-In blocks tab of the Blocks Editor. The following is not a comprehensive list of drawers or blocks. Each drawer that is listed has a select few important or unreferenced blocks. Each block is named and then explained and demonstrated.

The Definitions drawer

The following blocks can be found in the Definitions drawer.

ProcedureWithResult

The ProcedureWithResult block allows you to create a subroutine of blocks to which you can pass data using arguments. You can then have blocks in the ProcedureWithResult process the data and return the output to the block that initially called the procedure. The arguments are optional.

When you create a ProcedureWithResult, a call block with the same name is created in the My Definitions drawer. The call block has sockets with names to match any name blocks placed into the ProcedureWithResult block.

When you place a name block in an

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