title: Combobox change event to revert back to value before change
body: <p>I need to detect the selected value of a comboBox and if a certain value is selected produce a confirm dialog. If the confirm is false, I need to revert back to the value before the change took place. I'm trying with a hidden field that holds the value before the change. this is not working...</p>
  
  <p>UPDATE: when I addede the alert to see if the value was actually being set in the hidden field, everything works fine. If I remove the alert the change never happens. Some kind of timing issue? I replaced the alert with a delay and it didnt fix anything. Any ideas whats going on?</p>
  
  <pre><code>jQuery('#cboCityID1').focus(function() {
      if(jQuery('#cboCityID1').val() != '') {
          jQuery('#hiddencity1').val(jQuery('#cboCityID1').val()); 
      }
  });
  
  jQuery('#cboCityID1').change(function() {
  
      alert("as debug 1: " + jQuery('#hiddencity1').val());
  
      if(jQuery('#cboCityID1').val() == '') {
          var r = confirm("Are you sure");
          if(!r) {
              jQuery('#cboCityID1').val(jQuery('#hiddencity1').val()); 
          }
      }
  });
  </code></pre>