Skip to content

Instantly share code, notes, and snippets.

@SamKr
Created August 8, 2018 07:27
Show Gist options
  • Save SamKr/2ff8add277659c64ff1d39183bc9e99b to your computer and use it in GitHub Desktop.
Save SamKr/2ff8add277659c64ff1d39183bc9e99b to your computer and use it in GitHub Desktop.
var start = new TimeSpan(2, 45, 0);
var end = new TimeSpan(4, 0, 0);
var now = DateTime.Now.TimeOfDay;
if ((now > start) && (now < end))
{
return;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment