+ Reply to Thread
Results 1 to 2 of 2

To chnage date to Weeknum

  1. #1
    Registered User
    Join Date
    01-22-2013
    Location
    Bangkok, Thailand
    MS-Off Ver
    Excel 2007
    Posts
    56

    To chnage date to Weeknum

    Dear All,

    I am trying to change date Format DD-MMM-YY to Week format Week#-MMM.

    for Example
    01-Jan-2015 = Week1-Jan
    11-Jan-2015 = Week2-Jan
    01-Feb-2015 = Week1-Feb

    You can see in attached file.

    Change Date to week.xlsx


    Please help me for this one.

    Best regards,

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,063

    Re: To chnage date to Weeknum

    This isn't as simple as your question suggests. What is a week number & when does it start?

    IF a week is the first seven days in any month, this will work:

    =IF(A2="","","Week "&(INT((DAY(A2)-1)/7)+1)&"-"&TEXT(A2,"mmm"))

    However, if Week 1 begins on the 1st and week 2 on the next Monday, then you need this:

    =IF(A2="","","Week "&INT((13-WEEKDAY(A2-1)+DAY(A2))/7)&"-"&TEXT(A2,"mmm"))
    Last edited by Glenn Kennedy; 01-31-2015 at 10:06 AM.
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Excel 2007 : Convert Weeknum to a date.
    By jacarutu in forum Excel General
    Replies: 5
    Last Post: 03-30-2012, 09:25 AM
  2. Chnage format of Date in Listbox
    By aman1234 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-30-2012, 10:24 AM
  3. Date Function:WEEKNUM
    By Bob Phillips in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-06-2005, 06:05 AM
  4. [SOLVED] chnage date from tuesday 4 January 2005 10:39.26 to 04/01/2005
    By Jonny1975 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-06-2005, 03:05 AM
  5. chnage date from tuesday 4 January 2005 10:39.26 to 04/01/2005
    By Jonny1975 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-06-2005, 02:05 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1