<div>Can you also show us your method that parse and add the feature to the layer?</div><div><br></div>I think another good way to explore is to use firefox and firebug.<div><br></div><div>With firebug, you can add breakpoints and the go step-by-step...</div><div><br></div><div><br></div><div>Whith that, you should put a breakpoint into your method that parse and add features to layer and another one into the cluster strategy (Think to not use the OpenLayers minimised but the complete source) to see if software run into the class correctly...</div><div><br></div><div><br></div><div>Hope my english is quite understandable.... :)</div><div><br></div><div><br></div><div><br></div><div>Jérome</div><div><br></div><div><br></div><div><br></div><div><div><div>Le 28 août 09 à 14:01, Max Stephan (via Nabble) a écrit :</div><br class="Apple-interchange-newline"><blockquote type="cite">Hi Jerome, <br><br>thanks for your reply. I already tried that but it causes an error ("this.layer.events" is null or no object) and the map content isn´t shown. <br><br>Any other ideas? <br><br>Greets, <br>Max Stephan <br><blockquote class="quote light-black dark-border-color"><div class="quote light-border-color"> <div class="quote-author" style="font-weight: bold;">Jerome Freyre wrote:</div> <div class="quote-message shrinkable-quote">Hi Max, <br><br>Personnally, when I use Cluster Strategy, I create separatly the strategy and the I activate it. <br><br><pre>                
                        var strat = new OpenLayers.Strategy.Cluster({distance:20});
                        vectorLayer = new OpenLayers.Layer.Vector("Vektorlayer",{
                        strategies: [
                                strategy
                        ],
                        styleMap: vectorStyle2, maxResolution: 19});
                        strat.activate();
</pre><br><br>Hope it will be usefull.... <br><br>Sincerly, <br>Jérome <br><br><blockquote class="quote light-black dark-border-color"><div class="quote light-border-color"> <div class="quote-author" style="font-weight: bold;">Max Stephan wrote:</div> <div class="quote-message shrinkable-quote">Hi everybody, <br><br>I`m having problems getting the cluster strategy to work. It simply makes no difference in terms of appearance if I add it to the VectorLayer or not. <br><br>This is my code for the layer: <br><pre>                vectorLayer = new OpenLayers.Layer.Vector("Vektorlayer",{
                        strategies: [
                                new OpenLayers.Strategy.Cluster({distance:20})
                        ],
                        styleMap: vectorStyle2, maxResolution: 19});</pre><br><br>The reason why I want to add it is that I have 480 Features alltogether on my map and even when zooming into some areas there are still around 150 features left in the bbox causing InternetExplorer to slow down (don´t know if it´s the same case with Firefox, but I gotta use IE to use ADODB-Connection to an Access Database in the Intranet). <br><br>Those features are created and added step by step with an addVector-method I have implemented that reads out the coordinates and attributes of the database for a single feature and then jumps to the next entry and repeats the procedure till all features have been added. <br><br>greets and thx in advance <br>Max Stephan <br></div> </div></blockquote> </div> </div></blockquote> </blockquote></div><br></div>
<br><hr align="left" width="300">
View this message in context: <a href="http://n2.nabble.com/Cluster-strategy-not-working-tp3533851p3534250.html">Re: [OpenLayers-Users] Cluster strategy not working</a><br>
Sent from the <a href="http://n2.nabble.com/OpenLayers-Users-f1822463.html">OpenLayers Users mailing list archive</a> at Nabble.com.<br>