C# Set DateTime Variables Time to Default Time (12:00:00:00)

To Standardize the Time for all DateTime Value.

String NewRentalCommenceDate = RentalCommenceDate.ToShortDateString();
RentalCommenceDate = Convert.ToDateTime(NewRentalCommenceDate);
String NewRentalDueDate = RentalDueDate.ToShortDateString();
RentalDueDate = Convert.ToDateTime(NewRentalDueDate);

0 comments: