Skip navigation
All Places > ArcGIS AppStudio > Blog > 2020 > July
2020

We are excited to announce that ArcGIS AppStudio 4.3 is now available as a public beta. Downloads are available through the Early Adopter Community. We encourage you to experience the new features and enhancements (and report bugs) by participating in the beta program. Your feedback will help us greatly improve AppStudio and deliver a stable, high-performance product to everyone for the final release.

 

Get your apps ready for Google Play requirements

Starting  August 3rd, 2020, new apps submitted to the Google Play Store must target Android 10 (API level 29), and by November 2nd, 2020, all apps that are updated must target at least Android 10 (API level 29). We have made significant changes to AppStudio Desktop, Player, AppFramework, and templates to make sure your AppStudio apps will meet Google Play’s target API level requirement. Review this blog post to learn more details about the changes for Android 10. We highly encourage you to download the AppStudio 4.3 beta from the Early Adopter Community and test your app to make sure it continues to work well on Android 10 devices.

 

What’s new

This release also rolls out many exciting new features and enhancements. Highlights of the beta release include:

 

  • Support for ArcGIS Runtime SDK version 100.8.
  • AppStudio Player
    • Supports configuring portal URL and portal Name with Mobile Device Management (MDM).
    • Supports applying and switching custom profiles without using the app link.
  • Map Viewer Template
    • Supports offline routing in mobile map packages (MMPK).
    • Includes a new Sketch tool that allows you to snip, sketch, and share screenshots.
    • Supports custom pop-ups for both HTML descriptions and attributes fields.
  • Quick Report Template
    • Supports copying report values and pasting to new reports.
    • Includes a new Summary page that allows you to review and edit the report before submitting it.
  • 3D Scene viewer Template 
    • Supports identifying features for the Map Image layer, Feature Layers, and Feature collection layers.
    • Supports showing and viewing attachments.
  • AppFramework
    • Provides access to the operating system theme.
    • Includes a new version number and Battery component.
    • Enhancements to DocumentDialog to use the native OS file picker dialog.
    • Improved support for file handing.
    • Improved support for multiple attachments in Email Composer.

 

Review this documentation in the Early Adopter Community to see a comprehensive list of new features, enhancements, and bug fixes.

 

Getting Started

The beta program is open to anyone – join the Early Adopter Community today to gain access to the latest version of ArcGIS AppStudio 4.3 Beta.

 

  • AppStudio Desktop - You can download the beta version of AppStudio Desktop 4.3 here.
  • AppStudio Player (iOS) - AppStudio Player 4.3 (Beta) is available via Apple's TestFlight. Please click on this link to download.
  • AppStudio Player (Android) - AppStudio Player 4.3 (Beta) is available via the Android Beta Program. Please go to this link to download it.

 

You are now all set to start testing the AppStudio 4.3 Beta!

 

Feedback

Your feedback is much appreciated and will help us to improve the final release of ArcGIS AppStudio 4.3. For bugs or other issues you may find, please submit a bug report or email us at appstudiofeedback@esri.com.

 

The ArcGIS AppStudio 4.3 final release is scheduled for late August. We want to thank everyone who contributes to this release in advance, and we wish you happy testing!

 

Learn more about AppStudio:

  • Find AppStudio contents at 2020 Esri User Conference. 
  • New to AppStudio? Check out this website to learn more about what ArcGIS AppStudio can do to you and your organization.
  • Check out our recent workshop recordings to get started with creating native apps using AppStudio.
  • Let us know about your creations built using AppStudio to be featured in AppStudio Showcase Gallery.
  • Provide your ideas and suggestions to us on ArcGIS Ideas site.
  • Follow us on Twitter @ArcGISAppStudio to keep up-to-date on the latest information.
  • The AppStudio team periodically hosts workshops and webinars; please sign up for the AppStudio newsletter if you are interested in information regarding AppStudio events.

 

Working with the file system is an important part of developing any AppStudio app. For an Android app, up until targeting Android 10, when you gave an app storage permission, it could access any file on the device. When an app targets Android 10, Google enforces the concept of Scoped Storage, which enhances user control and privacy while cutting back the file clutter that removed apps leave behind. 

 

Google is changing the rules for submissions to Google Play. Starting on August 3, 2020, all new apps submitted to the Google Play store must be built for Android 10 by targeting SDK 29. And starting on November 2, 2020, all new apps and existing apps (app updates) must target Android 10 by targeting SDK 29. The upcoming AppStudio 4.3 and AppStudio 4.3 Beta will have default Android targetSdkVersion set to SDK 29.

 

This blog discusses exactly what this means and how it may impact users of your app.

 

How will users be affected? 

 

Users of your apps will be affected if both of the scenarios are applied,   

  • They have installed an older version of your app and have upgraded to a version of your app built with AppStudio 4.3 (Android targerSdkVersion set to SDK 29), AND,
  • They have unsaved work ( e.g. input, forms, data, surveys, images, databases, etc ) from the older version of your app.

 

You should advise your users to save their work before installing app updates targeting SDK 29. This may mean submitting their unsaved work online.

 

Currently, up until targeting SDK 28, when your user uninstalls your app, their work will persist on storage location like /sdcard. After targeting SDK 29, when the user uninstalls your app, data stored with the app will be deleted. 

 

How you should prepare your apps and users?

 

The worst-case scenario, after targeting SDK 29, is the app will not be able to access old data from before. 

 

The primary method of preparation is you should give users ample warning as soon as possible. Tell them that changes are coming and that they should prepare. Also, tell them to save their work online before upgrading their application. Such messaging can mitigate any loss of data better than any app code will do.

 

The secondary method of preparation is to offer your users in-app mechanisms for access or migration of their data. However, as indicated, Google is closing off access to the older files location and you have limited opportunities to maximize your user’s success with this option. Also, you don’t want to implement migration code that’s stuck in your codebase for, potentially, forever (as you don’t know when the user will conduct the migration).

 

AppStudio 4.3 and Android Scoped Storage

 

AppStudio 4.2 default Android targetSdkVersion set to SDK 28. And the upcoming AppStudio 4.3 and AppStudio 4.3 Beta will have default Android targetSdkVersion set to SDK 29. So when your app is built using AppStudio 4.3, it will already target SDK 29 required by Google Play. 

 

If you wish to opt-out and do not want to target SDK 29, you can edit appinfo.json to change the "targetSdkVersion" property to 28. 

 

"deployment": {
  "android": {
    "targetSdkVersion": 28
  }
}

 

If you want to keep the targetSdkVersion at SDK 28 but still want to use the new Android Scoped Storage, you can set the "scopedStorage" property in appinfo.json. This will allow apps to get ready with the changes in AppFramework.userHomePath without incurring losing access to the old location.

 

"deployment": {
  "android": {
    "scopedStorage" : true
  }
}

 

The changes in AppFramework.userHomePath 

 

For apps targetting SDK 28 and apps setting "scopedStorage" property to false the AppFramework.userHomePath will default to “/sdcard”. For apps targetting SDK 29 or apps setting "scopedStorage" property to true the AppFramework.userHomePath will default to Scope Storage location.

 

"/storage/emulated/0/Android/data/com.myorg.myawesomeapp/files"

 

Apps should use AppFramework.userHomePath or ~ to save data using the following code snippet as a guide:

 

let fileInfo = AppFramework.fileInfo( "~/Data/file.dat" );
let fileFolder = fileInfo.folder();
let data = "sample data";
fileFolder.makeFolder();
fileFolder.writeTextFile( fileInfo.fileName, "sample data" );

 

Apps should use AppFramework.userHomePath or ~ to read data using the following code snippet as a guide:

 

let fileInfo = AppFramework.fileInfo( "~/Data/file.dat" );
let fileFolder = fileInfo.folder();
let data = fileFolder.readTextFile( fileInfo.fileName );

 

The above methods are supplied as a guide because:

  • The fileInfo object is a good way to expand userHomePath via the ~ shorthand
  • The fileInfo object contains an easy way to access a FileFolder object ( which is needed to ensure the folder actually is created before writing files within )

 

Apps effectively using AppFramework.userHomePath or ~ will automatically migrate to the newer location.

 

When apps target SDK 28 and below (i.e. AppStudio 4.2 and below), we are currently defaulting AppFramework.userHomePath to “/sdcard”.

 

When apps target SDK 29 and above (i.e. AppStudio 4.3 and above), we will be setting AppFramework.userHomePath to a new location defined by the Scoped Storage. And when uninstalling and re-install, data will be gone.

 

New AppStudioHomeLocation enumeration

 

In AppStudio 4.2, we have introduced a new StandardPaths.AppStudioHomeLocation enumeration. To use it,

 

let userHomePaths = AppFramework.standardPaths.standardLocations( StandardPaths.AppStudioHomeLocation );

 

On Android, this will return a string array containing two values, the first value will contain the new target SDK 29 userHomeLocation location and the second value will contain the target SDK 28 userHomePath.

 

[ "/storage/emulated/0/Android/data/com.myorg.myawesomeapp/files", "/sdcard" ]

This location could be to check the old SDK 28 location to see if there was old content that we could migrate to the user location.

 

This could be used to implement data migration, however, only a small group of users will be able to use it to migrate their data effectively. i.e. those users who haven’t upgraded their phone to Android Q, or those users who are running a target SDK 28 version of your app.

 

AppStudio Player as a distribution tool 

 

We have made the changes in AppStudio Player 4.3 to target Android 10, and introduced a new feature called Custom Profile so you could better use AppStudio Player as a distribution tool. Using AppStudio Player as a distribution tool for your AppStudio apps would make sure that your apps would continue to work since the changes are done by us in the AppStudio Player side.

 

If you have any questions regarding this or anything related to AppStudio, please leave your comment below or reach out to us at appstudiofeedback@esri.com. 

 

  • New to AppStudio? Check out this website to learn more about what AppStudio for ArcGIS can do to you and your organization. 
  • Become an AppStudio for ArcGIS developer! Watch this video on how to sign up for a free trial. 
  • Follow us on Twitter @ArcGISAppStudio  to keep up-to-date on the latest information and let us know about your creations built using AppStudio to be featured in the AppStudio Showcase.
  • The AppStudio team periodically hosts workshops and webinars; please sign up for the AppStudio newsletter if you are interested in information regarding AppStudio events.