Click here to Skip to main content
15,907,492 members
Articles / Programming Languages / C#

Get week from Specific date

Rate me:
Please Sign up or sign in to vote.
4.67/5 (3 votes)
22 Apr 2010CPOL 10.1K   1  
DateTime date = DateTime.Now;System.Globalization.CultureInfo cult_info = System.Globalization.CultureInfo.CreateSpecificCulture("no");System.Globalization.Calendar cal = cult_info.Calendar;int weekNo = cal.GetWeekOfYear(date, cult_info.DateTimeFormat.CalendarWeekRule,...

Views

Daily Counts

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



Comments and Discussions