can&#39;t manage my first control    <br><br>hi,<br><br>I am still trying to develop a new control for my application. The control is called ParallelLine. I am sorry to bother you with this again. <br>I copied most of the code from ModifyFeature control as Ivan suggested.<br>
<br>As in the ModifyFeature control, this new control includes a selectControl variable. <br><br>The problem is that when I activate my control the selectControl variables seems not to be propperly initialized.<br><br>To test it, I added an  alert to the SelectFeature activate method to see if it is called when instanciating the selectControl variable of my new control. And it isn&#39;t. I have tried to see what happen when I activate the original ModifyFeature, and of course, it works fine.<br>
<br>I think I have forgotten to change some url. Otherwise I do not have any idea what is going on.<br>I must have you all quite confused.<br><br>/////////////////////////////////////////////////////////////////<br>This is how I call the js files.<br>
/////////////////////////////////////////////////////////////////<br><br>&lt;script src=&quot;../OpenLayers.js&quot;&gt;&lt;/script&gt;<br>&lt;script src=&quot;../lib/OpenLayers/Control/ParallelLine.js&quot;&gt;&lt;/script&gt;<br>
<br>/////////////////////////////////////////////////////////////////<br>This is how I initialize the parallelLine control<br>/////////////////////////////////////////////////////////////////<br>    initialize: function(layer, options) {<br>
        this.layer = layer;<br>    OpenLayers.Control.prototype.initialize.apply(this, [options]);<br><br>        var control = this;<br>    var selectOptions = {<br>            geometryTypes: this.geometryTypes,<br>        hover: true,<br>
            clickout: this.clickout,<br>            toggle: this.toggle<br>        };<br><br>        this.selectControl = new OpenLayers.Control.SelectFeature(<br>            this.layer, selectOptions<br>        );<br><br>
        this.layer.events.on({<br>            &quot;beforefeatureselected&quot;: this.beforeSelectFeature,<br>            &quot;selectFeature&quot;: this.selectFeature,<br>            scope: this<br>        });<br>    <br>
<br>        // Regiter the events (sigte)<br>    this.layer.events.register(&quot;mousemove&quot;, this, this.mmove );<br>    this.layer.events.register(&quot;mousedown&quot;, this, this.mdown );<br>    }<br><br>/////////////////////////////////////////////////////////////////<br>
This is how I activate the parallelLine control.<br>/////////////////////////////////////////////////////////////////<br>    activate: function() {<br>    //this function is called. Sure.<br>        return (this.selectControl.activate() &amp;&amp;<br>
                OpenLayers.Control.prototype.activate.apply(this, arguments));<br>    }<br><br>This is the activate method from SelectFeature.js which seems to be never called.<br>    /*From SelectFeature.js*/<br>    activate: function () {<br>
    alert(&quot;yes&quot;);<br>        if (!this.active) {<br>            this.handlers.feature.activate();<br>            if(this.box &amp;&amp; this.handlers.box) {<br>                this.handlers.box.activate();<br>            }<br>
        }<br>        return OpenLayers.Control.prototype.activate.apply(<br>            this, arguments<br>        );<br>    }<br><br>I promise  not to bother you again in one week.<br>ok two weeks then.<br>