I must have built up such that I have a datetime which gets added antale day as it should go forward. and then I have time as it should set off in relation to 04/10/16 to 10/09/16
I do not care about the time which is in datetime. It should not I use for anything. What I need out of this is exactly how many days there are from that time.
Datetime dateString = "4/10/2016 8:30:52" //I pretend that it comes from the database, it was more in terms of see what come there.
DateTime dt = DateTime.Now.AddDays(5);
DateTime objects support basic operators and will return
DateTime DateTimeB = DateTime.Now.AddDays(5); DateTime DateTimeA = DateTime.Now; TimeSpan difference = DateTimeA - DateTimeB;
you can then use the
TotalDays property of the timeSpan.