CSharp examples for System:DateTime Week
Day Of Week
using System.Text; using System.Linq; using System.Collections.Generic; using System;//from ww w .j a v a 2 s .com public class Main{ public static int DayOfWeek(this DateTime date) { if (date.DayOfWeek == System.DayOfWeek.Sunday) return 7; else return (int)date.DayOfWeek + 1; } }