Professional Documents
Culture Documents
Exercise
Build Native Apps Using AppStudio
for ArcGIS
Section 5 Exercise 1
08/2018
Do-It-Yourself Geo Apps MOOC
Instructions
Use this guide and ArcGIS Online to reproduce the results of the exercise on your own.
Note: ArcGIS Online is a dynamic mapping platform. The version that you will be using for
this course may be slightly different from the screenshots you see in the course materials.
Time to complete
Approximately 50-60 minutes
Technical note
To take advantage of the web-based technologies available in ArcGIS Online, you need to
use a fairly new version of a standard web browser, such as Google Chrome, Firefox, Safari,
or Internet Explorer. Older web browsers may not display your maps correctly.
For information on supported browsers, visit the documentation (https://bit.ly/2pIIN2T).
Introduction
In Chris's lecture for this section, you learned that native apps are created for a specific
platform. They are installed directly onto a device, as opposed to a web app, which is not on
a specific device but accessed with a web browser. With AppStudio for ArcGIS, you can
convert your web maps into beautiful, consumer-friendly mobile apps for Android, iOS,
Windows, and more.
You can also publish geo apps to popular app stores using your own brand without touching a
piece of code.
There are two licensing models for AppStudio: Basic and Standard. AppStudio Basic is free
and allows you to build apps from templates that you can then publish to Apple, Google, or
other app stores. AppStudio Standard builds on this functionality by allowing you to develop
more custom apps, but it requires a yearly subscription. In this exercise, you will use
AppStudio Basic to create your native apps.
Part I - Guided
The exercises in Sections 2 through 6 have two parts: the Guided part provides step-by-step
instructions, and the Do-It-Yourself part lets you explore further and build your own geo apps.
In the Guided part of this exercise, you will build a native app using AppStudio for ArcGIS, a
mobile field collection app for finding and mapping bike parking areas.
First, you will create a bike-parking collection app using the Quick Report template. This
template allows users to capture the location of a feature, record information about it, and
even attach a photo or video taken with a mobile device. All observations are submitted to an
online service where you can access them through other web or mobile apps. Then, you will
create a map to learn how to show the results of a mobile app.
You will not actually publish your app to an app store in this exercise, as it would require you
to sign the apps and then receive verification from Apple (https://apple.co/19ele5e) or
Google (https://bit.ly/2MRbKSG). Signing your app is a process that confirms that you, the
app creator, are trusted by the app's distributor (Apple or Google, in most cases). For now, if
you want to publish an app after completing the exercise, you'll need to sign it on your own.
In the future, Esri will handle the signing and publishing process for the apps that you create
with AppStudio.
d Choose a location to download the file to, and then unzip the contents to an easily
accessible location on your computer.
This URL is a REST endpoint, which is a URL provided as a way for web apps to access data
through a feature service or any other web service. REST is a common way for web
developers to access and share data or services. You could paste that REST URL into a web
browser and see the services directory page with more details.
You will use the REST endpoint of an existing public-facing feature service to publish a new
hosted feature layer for your app to use. When you create a hosted feature layer in your
ArcGIS Online account like in the workflow below, a new, empty feature service is published
behind the scenes, allowing you to collect your own set of data.
a In the private (or incognito) browser tab, browse to arcgis.com, and sign in to ArcGIS
Online using your course credentials.
Note: The Section 1, Exercise 1 PDF explains how to determine your ArcGIS Online
credentials (username and password) for this course. If you have trouble signing in, you can
check the Common Questions on the Help tab, look in the forum, or use the Have A Question
form on the Help tab.
e In the Create A Feature Layer dialog box, click the From URL tab, and then copy and
paste the following text into the URL field:
https://services5.arcgis.com/oFt0RLBVxpTM7Dv0/ArcGIS/rest/services/Bike_Parking/FeatureServer
Note: When copying and pasting the service URL from the exercise PDF, a space is
sometimes introduced in the URL. If you receive a message that the URL is invalid, check to
ensure that there are no spaces in the URL.
f Click Next three times to accept the layer and map extent defaults.
g On the metadata page, type the following information to specify details for the feature
layer:
• For Title, type Bike Parking, and append your first and last names so the feature layer
has a unique name.
Note: Because there are many other students creating a similar feature layer, adding your first
and last name will ensure that yours is unique.
The completed dialog box should look similar to the image below.
h Click Done.
Note: Another way you can create an empty hosted feature layer for your app is to build one.
From your Content page, you can create items, including feature layers. See this link (https://
bit.ly/2L1vn8U) for more information. For this exercise, you are copying an existing feature
layer, which already has all of the attribute fields created.
After the hosted feature layer is created, the item page displays.
In the Layers section, there is a function called Disable Attachments. You can allow users to
attach images and other files to individual features in a hosted feature layer. This is useful, as
it allows users of your app to associate photos to specific features. The attachments option is
a toggle link. When attachments are enabled, the link reads Disable Attachments. When
attachments are not enabled, the link reads Enable Attachments.
i In the Layers section, confirm that the link reads Disable Attachments, as shown below.
Users can capture and add attachments of their field observations (such as photos) with this
setting.
k In the Share dialog box, check the Everyone (Public) box, and then click OK.
In AppStudio Basic, only public feature services can be used to create native apps, so you
must share the service with everyone.
q Scroll down and verify that the editing settings are configured as follows:
r If you made any changes, click Save; otherwise, continue to the next step.
b Scroll down until you find the Create Your App button.
d At the top of the page, click Quick Report, or scroll down to the section for the Quick
Report app template.
g On the left, in the App Info section, type the following information in the appropriate
fields:
h Click the Thumbnail icon, and from the Exercise5_Bike Parking folder, add the
bike_thumbnail.png file.
The thumbnail icon will now display in ArcGIS Online and on your mobile device in AppStudio
Player for ArcGIS.
i Click the Launch Image icon, and from the same folder, add the bike_background.jpg file.
The launch image is the image that displays when your app is loading on a device.
j Click the App Icon icon, and add the bike_icon.png file.
The app icon is what would display on your mobile device if you were to publish your app to
the Apple or Google app store.
m In the Start Screen section, click the Start Background Image icon, and add the
bike_background.jpg file.
The Start Background image displays when your app has loaded. The user initializes the app
by clicking the New Report button, and the background image displays throughout the app.
o In the Choose Feature Service window, select the Bike_Parking feature service.
p Click Next.
q Click to the left of the Bike_Parking_[your name] feature layer item to expand it.
As indicated by the warning icon, the only way to build your app for iOS is to sign it. You can
build your app for Android and load it onto your device without signing it, but you cannot
publish it to the Google Play store. Similarly, you can build your app for Mac OS X, but
without signing it, users with newer operating systems that include Gatekeeper will not be
able to open it on their devices.
You will not sign or build your app, but you can view the app on your iOS or Android device
using the AppStudio Player.
Note: The graphics illustrate these steps for iOS devices. The workflow is the same for
Android devices, but the screenshots may differ slightly.
c If necessary, use the options icon at the top right to refresh the contents and find your
bike parking app.
g Select the app in the gallery again, and then tap Open App.
Note: You may need to swipe down first to refresh the apps list.
First, you will test your app by recording an observation. If you are not near any bike parking
facilities, it's fine to record an imaginary feature.
i Tap the type of report you are adding, and then tap Next.
j Move the map to set the location of the bike parking you are adding, and then tap Next.
Optionally, you can add a photo to show the bike parking feature associated with your
observation.
k To add an image, tap Camera or Album to take a new photo or use an existing one,
respectively.
l After you have decided on the photo that you would like to use, tap Next.
If you prefer not to add a photo, you can tap Next.
m Tap Next and complete the details form, and then tap Submit.
If your feature was added successfully, you will see a confirmation.
n Tap Done.
o If you want, create more features using the app, which will let you see more results when
you add them to a web map.
Congratulations! You just created and used an app to collect an observation of bike parking
facilities in your community. This is similar to the crowdsourcing app that you create in the
Section 3 exercise, but it is a native app, not a web app.
For this exercise, you have created a collection app to gather data. The web layer was created
first, and that is what is populated by the app. You will return to ArcGIS Online, find the
populated layer, and use it to create a web map.
a In the web browser, close the tab containing AppStudio for ArcGIS.
d On the item page, at the top right, click Open In Map Viewer.
You can see the default topographical basemap and your operational Bike Parking layer.
If you completed the preceding steps and added at least one bike parking feature using the
mobile app, you will see the feature on the map. You can return to the app and add more
features any time, and the map will reflect the changes.
e In the Contents pane, pause your pointer over the web layer, and click the Show Table
button.
In the attribute table, you can see the fields in the feature layer, which were in the existing
feature layer that you copied yours from.
Note: Your table will appear different from the graphic depending on the record or records
that you added using the mobile app.
f At the top, save your map by clicking the Save button, and then clicking Save As.
h Leave the default folder to save the map in, and click Save Map.
Now the map is ready to be shared. You can share web maps, but a better practice (especially
for sharing outside your organization) is to create and share a web app instead.
This exercise focused on native apps, so you will not create a second web app to share your
results. For great geo apps for sharing, you can learn about these apps in other sections:
This concludes the Guided part of the exercise. In the next part, keep going, apply what you
have learned, and do it yourself!
Part II - Do It Yourself
The Do-It-Yourself part has another optional goal to apply what you've learned already but
with less guidance. Build your own geo apps and use your creativity! Resources and samples
to help you are listed in the Learning Resources section at the end.
We do ask you that you read through this section even if you choose not to complete a DIY
project so that you will find and learn from your fellow students' work.
Be sure to share your app or other work with us. For high-quality or especially unique or
creative work, or just something that shows you've learned a lot in this class, Esri instructors
are watching the forums and will award special recognition at the end of the course. Only
properly tagged posts will be eligible for recognition.
Remember, have fun, explore, and experiment, but don't share maps or apps from the
Guided parts; only share the Do-It-Yourself parts!
The recognition for the best student work by Esri staff at the end of the course will be based
on the quality of the app or other work, as well as the quality reflected in the comments in the
forum post.
Learning Resources
Good work! In this exercise, you built a cross-platform native app using an AppStudio for
ArcGIS configurable app template, without any coding. We look forward to seeing your work
from the DIY part of the exercise, where there are great options for creating mobile or other
native apps.
Here are some more resources to continue learning:
Who says building native apps has to be challenging? (https://bit.ly/2vYNGqP)
E360 video: Configuring a Map Viewer (https://bit.ly/2PjDeCf)
Webinar: Building Cross-Platform Native Apps with AppStudio for ArcGIS (https://bit.ly/
2OHvZCQ)