Hallo Jürgen
Danke für deine Antwort.
var polygon = new GPolygon(Cpoints, strokeColor, strokeWidth, strokeOpacity, fillColor, fillOpacity);
lumkreis = map.addOverlay(polygon);map.removeOverlay(lumkreis);
die Referenz auf das Polygon steckt in polygon und nicht in lumkreis, daher removest du nicht das richtige. versuch mal
lumkreis = new GPolygon(Cpoints, strokeColor, strokeWidth, strokeOpacity, fillColor, fillOpacity);
map.addOverlay(lumkreis);map.removeOverlay(lumkreis);
Leider gehts noch nicht. Ich bekomme immer die Meldung "lumkreis is not defined". Kann es irgendwie damit zusammenhängen das die variable nur in der Polygon-Funktion gültig ist? Ich definiere sie aber doch am Anfang mit var lumkreis.
Gruss
Thomas