How to know that prefetching is done

Topics: Help, Windows Forms
Jan 29, 2013 at 10:05 AM

Hello together,

i need some help with the prefetch feature. I am using nearly the same code as in the demo sources and getting the tiles is working without a problem. I know that getting the tiles and saving them is done async. But in the demo sources I can't see how to know, that saving for all tiles is done. So if I use the export possibility directly after the prefetch, i can still see that there are I/O Operations in the tile cache, so i think there are not all tiles in my exported gmdb-file.

Does anybody have an idea how to i can check if all tiles are saved before i call the export function ?

Many thanks and greets

Hans

Jan 29, 2013 at 11:18 AM

check the source, on the prefetch form it writes how much left tiles for saving, i use:

MainMap.Manager.OnTileCacheComplete += new TileCacheComplete(OnTileCacheComplete);
MainMap.Manager.OnTileCacheStart += new TileCacheStart(OnTileCacheStart);
MainMap.Manager.OnTileCacheProgress += new TileCacheProgress(OnTileCacheProgress);

Jan 29, 2013 at 1:29 PM

Thank you very much for your reply.

I took a look into the FilePrefetcher form. Does this mean, everything should already be fine if I'am using the TilePrefetcher form just like in the demos application ? I am now using the newest version of you great Framework and things seems to be better now. I just want to be sure not do forget something and to have all wished tiles in my gmdb-File.

Jan 29, 2013 at 1:36 PM

if you see "all tiles saved" it's done