This project has moved. For the latest updates, please go here.

where I can find the map tiles are saved or cached when map is zoomed or panned

Nov 13, 2015 at 5:52 PM
Edited Nov 13, 2015 at 6:04 PM
I am using XAML map control lib from C# VS2013 on win 7.

I would like to know where I can find the map tiles are saved or cached when map is zoomed or panned ?

In TielImaheLoader.WPF.cs();
    /// <summary>
    /// Default folder path where an ObjectCache instance may save cached data.
    /// </summary>
    public static readonly string DefaultCacheFolder =
  Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData), "MapControl");
But, the folder C:\ProgramData\MapControl was not created when the map is opened , zoomed or panned.

Any help would be appreciated.
Coordinator
Nov 13, 2015 at 6:36 PM
Uncomment the following line in MainWindow.cs of the sample application:
TileImageLoader.Cache = new MapControl.Caching.ImageFileCache(TileImageLoader.DefaultCacheName, TileImageLoader.DefaultCacheFolder);
Nov 13, 2015 at 6:55 PM
Thanks! It works.

In each tile image, I need to find the borders of zip-code or county, which depends on the zoom level.

If a tile image covers two or more zip-codes or counties, I need to colorize the different zip-code with different colors so that we can see that zip-code or counties with different colors on the map clearly. The border color cannot be blurred.

But, the zip-code or county borders may be polygon lines.

How to find the borders and do the coloring ?

Any help would be appreciated.

thanks
Coordinator
Nov 13, 2015 at 8:34 PM
Take a look at the GetLatLonBoundingBoxUri method in TileSource.cs for some code that calculates the border coordinates of a map tile from its zoom level and x and y index.
Marked as answer by ClemensF on 11/19/2015 at 12:47 AM