I've created a bunch of Feature.Vectors from Point objects and assigned them a Style. Now I want to dynamically change the appearance of one of the features in real time; e.g., change it from red to blue. (I am NOT hovering over the feature.) I've tried changing its Style, then doing refresh() on the layer, or redraw(), etc, and either nothing happens or the feature disappears. Any suggestions? Thanks.
[GIS] How to change the appearance of a Feature.Vector that’s already displayed
openlayers-2symbology
Related Question
- [GIS] How to change the default color used by openlayers hover
- [GIS] How to Create Two Color Lines in QGIS
- [GIS] How to change the default color used by OpenLayers2
- [GIS] How to change the color of the layer after searching
- [GIS] How to use SLD to filter a WMS layer but without setting any styles
- [GIS] How to change the style of a vector layer on a button click
Best Answer
Redraw method should solve your problem, see my little example: OpenLayers: modifying feature style
UPD: I've modified my example a little bit: OpenLayers: modifying one feature style