title: Return if a date time is with 24 hours of another date time
body: <p>I am trying to compare a <code>DateTime</code> variable with another <code>DateTime</code> variable and if they are with 24 hours of one another then do something. So for example,</p>
  
  <pre><code>if (todaysDate == OtherDate) 
  {
  //do stuff only if otherDate is within 24 hours of todaysDate
  }
  </code></pre>
  
  <p>I understand I can use the operators found here, <a href="https://msdn.microsoft.com/en-us/library/ff986512(v=vs.110).aspx" rel="nofollow noreferrer">https://msdn.microsoft.com/en-us/library/ff986512(v=vs.110).aspx</a> to compare the dates, but none of those comparisons seem to give me what I'm wanting so was curious how this might be accomplished. </p>