+ Reply to Thread
Results 1 to 6 of 6

Formula to calculate date from, weekday-weeknumber-year

  1. #1
    Forum Contributor
    Join Date
    01-29-2011
    Location
    Bristol, England
    MS-Off Ver
    Excel 2003
    Posts
    471

    Formula to calculate date from, weekday-weeknumber-year

    Hi Guys
    I used to have this formula before but I have lost it. I tried to find my old thread but everything is wiped. No help from Google as well.

    Anyway could someone help me out.
    I have data as follows: weekday, weeknumber, year (col A, B and C respectively). using this data I would like to have a formula to populate the dates to col D


    Example (before):

    Weekday ----- Weeknumber ----- Year ----- Date

    Monday ------------ 1 ---------- 2012 -----
    Tuesday ----------- 1 ---------- 2012 -----
    Wednesday -------- 1 ---------- 2012 -----
    Thursday ---------- 1 ---------- 2012 -----
    Friday ------------- 1 ---------- 2012 -----
    Saturday ---------- 1 ---------- 2012 -----
    Sunday ------------ 1 ---------- 2012 -----
    Monday ------------ 2 ---------- 2012 -----
    Tuesday ----------- 2 ---------- 2012 -----
    Wednesday -------- 2 ---------- 2012 -----
    Thursday ---------- 2 ---------- 2012 -----
    Friday ------------- 2 ---------- 2012 -----
    Saturday ---------- 2 ---------- 2012 -----
    Sunday ------------ 2 ---------- 2012 -----
    Monday ------------ 3 ---------- 2012 -----
    Tuesday ----------- 3 ---------- 2012 -----
    Wednesday -------- 3 ---------- 2012 -----
    Thursday ---------- 3 ---------- 2012 -----
    Friday ------------- 3 ---------- 2012 -----
    Saturday ---------- 3 ---------- 2012 -----
    Sunday ------------ 3 ---------- 2012 -----


    Example (after):

    Weekday ----- Weeknumber ----- Year ----- Date

    Monday ------------ 1 ---------- 2012 ----- 02/01/2012
    Tuesday ----------- 1 ---------- 2012 ----- 03/01/2012
    Wednesday -------- 1 ---------- 2012 ----- 04/01/2012
    Thursday ---------- 1 ---------- 2012 ----- 05/01/2012
    Friday ------------- 1 ---------- 2012 ----- 06/01/2012
    Saturday ---------- 1 ---------- 2012 ----- 07/01/2012
    Sunday ------------ 1 ---------- 2012 ----- 08/01/2012
    Monday ------------ 2 ---------- 2012 ----- 09/01/2012
    Tuesday ----------- 2 ---------- 2012 ----- 10/01/2012
    Wednesday -------- 2 ---------- 2012 ----- 11/01/2012
    Thursday ---------- 2 ---------- 2012 ----- 12/01/2012
    Friday ------------- 2 ---------- 2012 ----- 13/01/2012
    Saturday ---------- 2 ---------- 2012 ----- 14/01/2012
    Sunday ------------ 2 ---------- 2012 ----- 15/01/2012
    Monday ------------ 3 ---------- 2012 ----- 16/01/2012
    Tuesday ----------- 3 ---------- 2012 ----- 17/01/2012
    Wednesday -------- 3 ---------- 2012 ----- 18/01/2012
    Thursday ---------- 3 ---------- 2012 ----- 19/01/2012
    Friday ------------- 3 ---------- 2012 ----- 20/01/2012
    Saturday ---------- 3 ---------- 2012 ----- 21/01/2012
    Sunday ------------ 3 ---------- 2012 ----- 22/01/2012


    Unfortunately I can not attach a spreadsheet to the post as I can not do any uploads from my workplace PC.
    Any help is much appreciated.
    Cheers
    Last edited by rain4u; 01-16-2012 at 06:59 PM.

  2. #2
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: Formula to calculate date from, weekday-weeknumber-year

    Hi rain4u,

    If you have the data in order you have shown here, you can simply put one date at starting and drag it down till end.

    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    DILIPandey, Excel rMVP
    +919810929744 (India), +971528225509 (Dubai), [email protected]

  3. #3
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,602

    Re: Formula to calculate date from, weekday-weeknumber-year

    is Monday (and other) a text value or date formated as dddd?

  4. #4
    Forum Expert snb's Avatar
    Join Date
    05-09-2010
    Location
    VBA
    MS-Off Ver
    Redhat
    Posts
    5,649

    Re: Formula to calculate date from, weekday-weeknumber-year

    the first monday in weeknumber 1 in year 2012 according to the ISO criteria:

    PHP Code: 
    =DATE(2012,1,4)-WEEKDAY(DATE(2012,1,4),2)+
    you can fill column D:

    Please Login or Register  to view this content.
    Last edited by snb; 01-16-2012 at 08:10 AM.



  5. #5
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Formula to calculate date from, weekday-weeknumber-year

    Try this, it uses the week commencing the first Monday in January as week 1
    Please Login or Register  to view this content.
    Select from the dropdowns in A2:C2 to see the results
    Attached Files Attached Files
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  6. #6
    Forum Contributor
    Join Date
    01-29-2011
    Location
    Bristol, England
    MS-Off Ver
    Excel 2003
    Posts
    471

    Re: Formula to calculate date from, weekday-weeknumber-year

    I'm still not used to the new format of excelforum.com
    I was going through all my attachments and stumbled up on my original thread. Funnily this thread still exists but when I'm using my own username to search all my posts it wont come up.

    the solution that works for me is as below:
    Please Login or Register  to view this content.

    Thank you for everyone for suggestions. Much appreciated. I have another question regards converting date to weeknumber and weekday index but i opened another thread for this
    http://www.excelforum.com/excel-prog...html?p=2683554

    Again thanks for help.
    Cheers

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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