Can selectors be used with bind and trigger in Jquery
<p>I am trying to use selectors with trigger and bind in jQuery. Its a simple code and i can't seem to get it working :(.</p>

<p>Here is what i am doing.</p>

<pre><code>$(document).ready(function (){

var ctrlChanged = jQuery.Event("CtrlChanged");

  //********** Any time a button with id*=btnAddNewEmailAddress is clicked, raise event that parent control has changed.
$('[id *= "btnAddNew"]').click(function () {
  $('[id *= "btnAddNew"]').trigger(ctrlChanged);
});
});
</code></pre>

<p>To subscribe to above event i am using following code.</p>

<pre><code>$('[id *= "btnAddNew"]').bind('CtrlChanged', function(){alert('Control Changed')})   
</code></pre>

<p>This combination is not working. When i click buttons with id matching "btnAddNew", i don't see alert message.</p>

<p>But if i replace [id *= "btnAddNew"] with something like </p>

<pre><code>$('body').trigger('ctrlChanged')
</code></pre>

<p>then corresponding change in bind </p>

<pre><code>$('body').bind('ctrlChanged', function(){alert('Control is changed'})
</code></pre>

<p>works like charm.</p>

<p>I am wondering if, trigger and bind works with selectors. I would think so... but they are not..</p>

<p>If yes then what am i doing wrong?</p>
