title: Dynamics crm onchange event Validating if a specified date falls within a date range
body: <p>I am trying to set up an onchange event within MS Dynamics CRM that brings up an alert if a date entered in a field falls outside of a specified range.</p>
  
  <pre><code>{
  if (crmForm.all.fielddate.DataValue &lt; 01/01/2010 || crmForm.all.fielddate.DataValue &gt;= 01/01/2011)
  {
  alert("Specified date falls outside of the date range") ;
  }
  }
  </code></pre>
  
  <p>This doesnt seem to work, am I using the correct date format? or am I missing something out?</p>
  
  <p>Thanks in advance for your help</p>
  
  <p>Brett</p>