Possible to create offline map from ArcGis 10.0 ?

2524
1
05-04-2015 07:32 AM
QKunZhu
New Contributor II

I know that only ArcGis 10.2 server or later can provide feature services to download .tpk files for offline use.

My problem is, my customer only has ArcGis 10.0 server and I need to be able to show offline map in iOS devices. in theory, .tpk files are just map tiles for different zoom levels and indexing file to know where to put map tiles. It should able to download ties from ArcGis10.0, but what about the indexing files?

Anyone tried this before? Any advice?

1 Reply
DiveshGoyal
Esri Regular Contributor

At 10.0, ArcGIS Server introduced the compact cache​ format.​ You can generate tiles in this format from the server, then copy them over to a Mac and manually "package" them into a .bundle file (technically, these are referred to as Document Packages ​) . To do this, create a folder on your Mac called "MyCache" whose internal structure contains the compact cache created by server. It should look something like this  -

MyCache

|__ _alllayers

     |__  L00

     |__  L01

     |__  ...

|__ conf.cdi

|__ conf.xml

Next, use the Finder application to rename the "MyCache" folder to "MyCache.bundle".  The operating system will now treat your folder as a single file, except it will have the compact cache embedded in it. Add this file to your XCode project, or drag it into your application's file sharing directory in iTunes. (This step is described in detail for tile packages here​ , except you'll be doing it with the bundle files instead of a tile package)

Then you can use this .bundle file with AGSLocalTiledLayer to display in the map view -

self.tiledLayer = [AGSLocalTiledLayer localTiledLayerWithName:@"MyCache"];