1,DateTime dt1 = DateTime.Parse(TextBox1.Text);
DateTime dt2 = DateTime.Parse(TextBox2.Text);
TimeSpan span = dt2 - dt1;
int ms = (int)span.TotalMilliseconds;
2, DateTime dt3 = DateTime.Parse(TextBox3.Text);
DateTime dt4 = DateTime.Parse(TextBox4.Text);
TimeSpan diff = d4 - d3;
int millisceonds = (int) diff.TotalMilliseconds;
|