Performance on the first load of the form

Topics: General
Mar 6, 2012 at 9:21 PM


I justed downloaded the library and it seems really to be a great work. Just the documentation is missing :-)

After I implemented a little test form I saw that on every start up (first time) of the form it takes around 10 - 20 seconds to load it. May I am doing something wrong. Here is my code

            GMapProvider.WebProxy = null;
            MainMap.MapProvider = GMap.NET.MapProviders.GMapProviders.GoogleMap;
            MainMap.MinZoom = 1;
            MainMap.MaxZoom = 17;
            MainMap.Zoom = 12;
            MainMap.Dock = DockStyle.Fill;
            MainMap.Manager.Mode = GMap.NET.AccessMode.ServerAndCache;
The second time I call the form it works quite fast. What am I doing wrong.
Thanks in advance
Mar 6, 2012 at 9:26 PM

you are in debug mode

Mar 6, 2012 at 10:55 PM
Edited Mar 6, 2012 at 10:56 PM

The wait is from the Google MapProvider. I found the reason why in another discussion here but basically thats the issue. Google map providers take awhile to load. 

If you change it to another provider, like Yahoo or OpenMaps it will load up much faster.

Mar 6, 2012 at 11:01 PM

Both of you are right. When I change to another provider it works faster. But still 10 seconds. When I start it from VS 2010 then it is slow. When I start it directy from the directory it's ok. Something strange in visual studio.



Mar 7, 2012 at 9:00 AM

wake up, in debug mode i've added three Thread.Sleep(5555); to see what version google has, use release build