Hi,
It's a idea, but I don't think you can unregister it. Because of the empty string as scope/context object.
You can try:
this.myScope ='';
lyr[0].events.register("featureadded",this.myScope, onFeatureAdded);

lyr[0].events.unregister("featureadded",this.myScope, onFeatureAdded);

You have to use the same object on register as on unregister. "this" has to be also the same "this".
When you try
lyr[0].events.unregister("featureadded",'', onFeatureAdded);
Then a new string object is created.
Regards
Slawomir


Am 15.04.2011 14:19, schrieb Mohammed Rashad:
how to unregister an event registered as


lyr[0].events.register("featureadded",'', onFeatureAdded);

--
Thanks && Regards
Rashad


_______________________________________________
Dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-dev

_______________________________________________
Dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-dev

Reply via email to