I am working on an android app that should have offline capabilities like getting map and edit the features. I have access to just ArcGIS online and ArcGIS developer portal. I do not have the ArcGIS Desktop access.
I am using Android Run-time SDK to achieve this, I have created map area for the web map in ArcGIS online and through SDK I can fetch the map-area but I am not able to generate the Geo-database for the feature. It gives me a run time exception "The feature service does not support geodatabase sync" .
Following line is giving me Runtime Exception:
GenerateGeodatabaseParameters parameters = defaultParameters.get();
I am stuck at this point, not able to proceed further, need to know if I am missing any configuration or is there any other way to achieve this.
Hi Devendra,
In ArcGIS Online, navigate to the feature service and click on the Settings tab. You can enable sync there:
Thanks for the response.
I have already enabled this.
I would like elaborate more in this concern:
STEP 1:
I get map area using:
ListenableFuture<List<PreplannedMapArea>> mapAreasFuture = offlineMapTask.getPreplannedMapAreasAsync();
I download map area using:
DownloadPreplannedOfflineMapJob job = offlineMapTask.downloadPreplannedOfflineMap(mapArea, mmpkFilePath);
Map area files that get downloaded are in 3 formats [ .mmap, .geodatabase, .tpk]
STEP 2:
I use following sample to generate geodatabase from the .tpk file and .geodatabase file. I am not sure about the uses of .mmap file.
and that's where I get exception while generating geodatabse.
Note:
GeodatabaseSyncTask.getFeatureServiceInfo().isSyncEnabled() is returning me 'false' everytime