it's your's

Convert Difference between 2 times into Milliseconds?

how to get difference between two date times into milliseconds?

DateTime dt1 = DateTime.Parse(maskedTextBox1.Text);
DateTime dt2 = DateTime.Parse(maskedTextBox2.Text);
TimeSpan span = dt2 - dt1;
int ms = (int)span.TotalMilliseconds;

Comments (4) -

  • Graham Pucker

    9/5/2017 5:12:56 AM | Reply

    I  believe  you have mentioned  some very interesting  details ,  appreciate it for the post.

  • Chadwick Isenbarger

    9/6/2017 5:57:44 AM | Reply

    Absolutely indited written content, thank you for information. "The earth was made round so we would not see too far down the road." by Karen Blixen.

  • Norris Buttel

    9/6/2017 5:58:25 AM | Reply

    You actually make it seem so easy with your presentation but I find this topic to be really something which I think I would never understand. It seems too complicated and extremely broad for me. I'm looking forward for your next post, I’ll try to get the hang of it!