Book Image

LiveCode Mobile Development Cookbook

By : Dr. Edward Lavieri
Book Image

LiveCode Mobile Development Cookbook

By: Dr. Edward Lavieri

Overview of this book

Table of Contents (17 chapters)
LiveCode Mobile Development Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Multiplying numbers


Multiplying numbers using LiveCode is a simple task. To demonstrate how to multiply two numbers, we will create a user interface that accepts two numbers, and when the equals sign is selected, the product of the two numbers will be displayed.

How to do it...

Follow the steps in this recipe to use LiveCode to multiply two numbers:

  1. Open LiveCode and create a new main stack.

  2. Set the background color of the default card to black.

  3. Drag a new text entry field to the card and set the following properties:

    • Name: fld_nbr1

    • Width: 88

    • Height: 31

    • Location: 194, 53

    • Font: Courier

    • Text size: 18

    • Align text right

  4. Drag a second text entry field to the card and set the following properties:

    • Name: fld_nbr2

    • Width: 88

    • Height: 31

    • Location: 194, 95

    • Font: Courier

    • Text size: 18

    • Align text right

  5. Drag a third text entry field to the card and set the following properties:

    • Name: fld_nbr3

    • Width: 88

    • Height: 31

    • Location: 194, 151

    • Font: Courier

    • Text size: 18

    • Align text right

  6. Drag a new label field...