Over a million developers have joined DZone.

Build an Android App in Five Minutes with Appery.io

· Java Zone

Learn more about how the Java language, tools and frameworks have been the foundation of countless enterprise systems, brought to you in partnership with Salesforce.

This tutorial will show you how to build an Android app in about 5 minutes and install it on a device.

  1. Sign up for Appery.io Starter (free) plan
  2. Create a new app by entering its name and clicking the Create button:
    2013-07-11_1514
  3. Build the mobile UI:
    AndroidUI
    Make the changes shown in Properties and make sure to rename the menu component.
  4. Update Options for the drop-down list:
    2013-07-11_1610
  5. Select the button and open Events tab
  6. Add Click > Run JavaScript, enter the following code:
    var times = Appery("menu").val(); navigator.notification.beep(times);

    This is Apache Cordova (PhoneGap) API to make the device beep x-number of times. As you are a building a hybrid app, you get access to all Apache Cordova API.

  7. Now let’s start the Android binary build. Click Export > .apk for Android:
    AndroidExport
  8. After a few seconds, you will be able to scan a QR code and install the app on your device (the file will also be saved on your computer):
    2013-07-11_1621
    If you don’t have a QR code scanner app, you can email the downloaded file to your phone.
  9. Run and test the app. Select the number of beeps and click the button.

Another way to test the app without installing it on the device is to use the Appery.io Tester available on Google Play.

Discover how the Force.com Web Services Connector (WSC) is a code-generation tool and runtime library for use with Force.com Web services, brought to you in partnership with Salesforce.

Topics:

Published at DZone with permission of Max Katz, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

The best of DZone straight to your inbox.

SEE AN EXAMPLE
Please provide a valid email address.

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.
Subscribe

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}