Select to view content in your preferred language

Tile Package weirdness: Flex CAN NOT consume some TPKs as an ArcGISLocalTiledLayer

2640
11
05-15-2013 02:32 PM
DirkVandervoort
Frequent Contributor
ArcGIS Desktop 10.1 SP used to create two TPKs

  • Using an mxd with vector data (Some points, lines and polygons with simple symbology using pure red, green and blue colors)

  • Using an AGS map service that serve the same content as the mxd (above)

20 LODs (required) and PNG output. Both the map service and the mxd use a state plane SRS.

The results:

  • The vector-generated TPK can be drag-n-dropped into ArcMap and display just fine.

  • A Flex API mobile map using the TPK as a ArcGISLocalTiledLayer does not display the TPK

  • The TPK generated from the AGS Map service can be drag-n-dropped into ArcMap and display just fine - albeit grainy (expected)

  • The Flex API mobile map using the TPK as a ArcGISLocalTiledLayer does displays the TPK just fine

So what's up? Am I missing some special magic to create the TPK?

The geoprocess:
CreateMapTilePackage D:\documents\Project\Maps\Some.mxd ONLINE D:\documents\Tiles/Tiles.tpk PNG 20 # # #


The Flex code:
<esri:Map width="100%" height="100%">        
     <esri:ArcGISLocalTiledLayer file="{File.documentsDirectory.resolvePath('Tiles/Tiles.tpk')}"/>
</esri:Map>
Tags (2)
0 Kudos
11 Replies
LloydHeberlie
Regular Contributor
Hello Lloyd;

Many thanks for the reply.

Just to be sure, this also applies even if we are using Flex and with Adobe Air and are packaging for iOS. This gives us access to plist and some other tricks...maybe there is a work around? But I assume the offline maps work fine with that setup on iOS and Android?

As we are a start up, this project can make or break us. Our potential client will install these large touch screens in various parts of his residential project. This device is going to be tough to connect to the internet, but we can request a specific device type to be installed. Users are supposed to be able to generate driving directions, and search functionality backed by a geocoding layer. This is in addition to offline maps ofcourse. So the question is...is there a specific device type (It cant be a tablet, something bigger and more awkward) and an operating system that the client can install. And on top of that we can build an app using a specific API that can provide offline maps, routing and geocoding? Maybe the windows 8 API?

Thanks again;
Raffi


Hi Raffi,

The "plist and other tricks" will only allow you to specify Adobe AIR setting for iOS, it won't put any off-line functionality into the ArcGIS API for Flex that you need.

The only out-of-the-box functionality in the ArcGIS API for Flex for off-line access is the use of the ArcGISLocalTiledLayer which uses a tiled package layer (*.tpk) which you would create using the ArcGIS Desktop product.  Any other functionality (off-line query, routing, geocoding, querying of layers, etc.) would have to be written by the developer (you/your staff).  Also, creating this off-line functionality would be no trivial task. 

The offline tiled map layers will work for iOS and Android using the ArcGIS API for Flex, but other than that you would have to write the functionality.

Based upon the off-line requirements you have mentioned in this forum post, I would recommend that you pursue the ArcGIS Runtime SDKs for Android and/or iOS.  Note that the offline features in the ArcGIS Runtime SDKs are currently (as of 12-16-2013) in beta.  The ArcGIS Runtime SDKs will give you the most immediate out-of-the-box off-line functionality which it sounds like you need.

If you are able to convince your client to go with one type of hardware device (Android or iOS) you may be able to avoid having to write two separate applications.

Hope this helps,
0 Kudos
raffia
by
Deactivated User
Hi Lloyd;

Many thanks for that detailed reply. I am very much in the clear now about this issue.

Kind Regards;
Raffi A
0 Kudos