Is it possible to configure the ModifyFeature control to edit features in multiple layers?

  • @drnextgis, we encourage people to wait for some time before accepting an answer--at least a few days--because alternative replies often emerge. Nobody should be in a rush to accept the first answer they get, but we hope that eventually they will accept some answer if it successfully responds to their question.
    – whuber
    Commented Jul 25, 2012 at 15:30

1 Answer 1


In this case you should create ModifyFeature controls for each layer. It is impossible to set multiple layers within one control.

  • What version of OL are you using? In the latest version at this time, ModifyFeature only accepts a single layer.
    – tubewurm
    Commented Jul 31, 2012 at 15:54
  • I have the same challenge. I want my user to be able to edit the feature on this drawlayer, but also to allready existing features loaded in another layer. Can I use one panel button to enable the modify controls on all the layers? Or wouldn't that work?
    – Jeroen
    Commented Dec 20, 2012 at 11:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.