Hi! I am using MapGuide version 3.1.0.9064 on a computer with Windows 10 Enterprise and IIS. Using Application definition (Fusion layout), with slate index.html I have a map with 864 layers on the map. I have made shortcut functions to turn of and on layers and layergroups on runtime:
Example: InitializeWebTier(); userInfo = new MgUserInformation(mgSessionId); siteConnection = new MgSiteConnection(); siteConnection.Open(userInfo); MgMap map = new MgMap(siteConnection); map.Open(resourceService, mgMapName); laygroup = GetLayerGroupByName(map, "mylayergroupname"); setLayerGroupVisible(laygroup, false); lay = GetLayerByName(map, "mylayername"); setLayerVisible(lay, false); map.Save(); map.Dispose(); The map is updated when I have run the code and run map.redraw(); in javascript. But I also want to update the legend so the user know what layergroups and layers have been turned on or off, so then I run map.reloadMap(); in javascript. First time I do this it works fine, but if I run the shortcut to change layer settings with som other layers turned on, and run map.reloadMap(); nothing happends on the legend. The map show the changed information after map.redraw(); so that works fine. What am I doing wrong? Why is it only possible to run map.reloadMap(); once for me? Is there a better call to refresh the legend, I think map.reloadMap(); is a real performance killer? I have searched information about this, but the only function I have found to update the legend is map.reloadMap();. //Dan -- Sent from: http://osgeo-org.1560.x6.nabble.com/MapGuide-Users-f4182607.html _______________________________________________ mapguide-users mailing list [email protected] https://lists.osgeo.org/mailman/listinfo/mapguide-users
