[mapguide-users] hide layer on box checked

dorra2007 dorrdor at yahoo.fr
Tue Oct 23 12:04:24 EDT 2007


Hi all;
I have read several posts about the setvisible function, but I have still
errors in my code  (I am using javascript/jsp).

Can someone give me a comprhensive code in javascript, wich show how i can
use the SetVisible method?
PS: My featuresource is a postgis database.

here is the code i used:

map=new MgMap();
map.open(resourceService,map_name);
layer=map.GetLayers().GetItem(layer_name);
layer.SetVisible(true);
map.save(resourceService);

the resourceService is not defined. In fact, what does it refers to?And how
can I define it?Should I create a map object?..

Many question, can someone help me?

Thank you in advance.
-- 
View this message in context: http://www.nabble.com/hide-layer-on-box-checked-tf4678398s16610.html#a13367254
Sent from the MapGuide Users mailing list archive at Nabble.com.



More information about the mapguide-users mailing list