private static int GetWeekOfYear(DateTime dt) { GregorianCalendar gc = new GregorianCalendar(); int weekOfYear = gc.GetWeekOfYear(dt, CalendarWeekRule.FirstDay/*设置第一天*/, DayOfWeek.Monday/*设置周一为一周的第一天*/); return weekOfYear; }