Arcgis Android-helloworld

Source: Internet
Author: User

Overview

Although the latest version of ESRI official web site is 10.2.4, it is very difficult to run in the example, there are always a variety of bugs. And because the beginner is Android, so don't want to waste time to get some configuration. Decide to familiarize yourself with v2.0.0 's ArcGIS for Android first.

1, the parameters of the simulator settings according to their own this log settings: Arcgis android-installation error:install_failed_insufficient_storage

2, after creating the default project by New->project->arcgis for Android->arcgis project for Android, open the Activity.java file under/src, modify the ' OnCreate ' method is:

1 @Override2      Public voidonCreate (Bundle savedinstancestate) {3         Super. OnCreate (savedinstancestate);4Mmapview =NewMapview ( This);//instantiating a Mapview object5Mmapview.setlayoutparams (Newlayoutparams (layoutparams.fill_parent, layoutparams.fill_parent));6Arcgistiledmapservicelayer Tilelayer =New7Arcgistiledmapservicelayer ("Http://services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer") ;//instantiating a layer8Mmapview.addlayer (Tilelayer);//add a layer to the map window9 Setcontentview (mmapview);Ten}
View Code

3, run, the result is:

Arcgis Android-helloworld

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.