title: onchange wont fire after programmatically changing html select dropdown
body: <p>I have a select inside HTML </p>
  
  <pre><code>&lt;select id="league" name="league"&gt;
  </code></pre>
  
  <p>which I'm listening for changes inside my javascript.</p>
  
  <pre><code>var league = dojo.byId("league");
  dojo.connect(league, "onchange", function (evt) { //do stuff }
  </code></pre>
  
  <p>Which works fine. 
  However I have a link that I can click which updates the select:</p>
  
  <pre><code>&lt;a href=javascript:void(0) onclick="updateSelection(league);"&gt; League &lt;/a&gt;
  </code></pre>
  
  <p>The link works as it updates the selected value of the select with the following function.</p>
  
  <pre><code>function updateSelection(NewLeague){
  dojo.byId('league').value = NewLeague;  // works
  dojo.byId('league').onChange;   //this isnt working
  //dojo.byId('league').onChange();  //this throws: TypeError: dojo.byId("league").onChange is not a function 
  }
  </code></pre>
  
  <p>My problem, as I've read through other stack posts is that programmatically updating the value wont trigger onChange, thus I need to call onchange in the code (shown above). As per the comments inline, the onChange isn't being triggered or throws an error. My first thought that it has something to do with the dojo.Connect which listens for onChange, but I havent found any information that says I <strong>cant</strong> do this, nor any explanation how to get around it.</p>
  
  <p>Any ideas?</p>