day =DateTime.Today;
取出今天日期,,,怎么算昨天的啊
谢谢
------解决方案--------------------------------------------------------
DateTime dt = DateTime.Today;
dt = dt.AddDays(-1);
dt.Date
------解决方案--------------------------------------------------------
DateTime dt = DateTime.Today;
Console.WriteLine(dt.AddDays(-1));
------解决方案--------------------------------------------------------
day = DateTime.Today.AddDays(-1);