[Solved] How do I add milliseconds to a DateTime object?


There is an AddMilliseconds() method:

var foo = DateTime.Now.AddMilliseconds(100);

Or, you can use a TimeSpan with Add():

var foo = DateTime.Now.Add(TimeSpan.FromMilliseconds(100));

solved How do I add milliseconds to a DateTime object?