接上判斷當日為本周第幾天,接下來迴圈獲取周一至當前日對應的日期: for (int j = 0; j < DayinWeek; j++) { //星期對應Date string date = DateTime.Now.AddDays(1 - DayinWeek + j).ToString("yyyy ...
接上判斷當日為本周第幾天,接下來迴圈獲取周一至當前日對應的日期:
for (int j = 0; j < DayinWeek; j++) { //星期對應Date string date = DateTime.Now.AddDays(1 - DayinWeek + j).ToString("yyyyMMdd"); }