+ Reply to Thread
Results 1 to 8 of 8

Index & Match Help for date lookup

  1. #1
    Registered User
    Join Date
    04-30-2019
    Location
    Stoke-on-Trent, England
    MS-Off Ver
    2016
    Posts
    21

    Index & Match Help for date lookup

    Hi Any help would be appreciated

    I am trying to get the dates on this sheet to auto fill with a formula when I create a new weeks sheet

    1.png

    When I create a sheet the week number is automatically added based on the name of the sheet
    e.g Sheet named WK 01 will display 01 in the Week cell

    The year will be a manual input

    what I would like is based on we know the week,year, day is for the dates to be worked out from a table on a different sheet (Ignore Numbers Row this will be entered manually each week)

    2.png

    I have attached the workbook so you can see what i mean
    Attached Files Attached Files

  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 2406
    Posts
    44,662

    Re: Index & Match Help for date lookup

    Confused.

    What do you want to see? Where do you want to see it?

    Why have you posted a cut-down sheet with no room for experimenting with formulae?
    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

  3. #3
    Registered User
    Join Date
    04-30-2019
    Location
    Stoke-on-Trent, England
    MS-Off Ver
    2016
    Posts
    21

    Re: Index & Match Help for date lookup

    I need the the formula on the date row (Row 5) above each day and not sure what you mean about cut down sheet, i've only hidden columns and row not being used

  4. #4
    Forum Expert shukla.ankur281190's Avatar
    Join Date
    05-17-2014
    Location
    Lucknow, India
    MS-Off Ver
    Microsoft® Excel® for Microsoft 365 MSO (Version 2503 Build 16.0.18604.20000) 64-bit
    Posts
    3,995

    Re: Index & Match Help for date lookup

    tRY

    d3=SUBSTITUTE(MID(CELL("filename",B1),SEARCH("]",CELL("filename",B1))+1, SEARCH("]",CELL("filename",B1))-SEARCH("[",CELL("filename",B1))-1),"WK ","")+0

    d5=INDEX('Date & Week'!$D$2:$D$736,SMALL(IF($D$3='Date & Week'!$A$2:$A$736,IF('Date & Week'!$B$2:$B$736=$D$4,ROW('Date & Week'!$A$2:$A$736)-ROW('Date & Week'!$A$2)+1)),1))

    Change above part with 2,3,4,5,6,7

    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.
    If I helped, Don't forget to add reputation (click on the little star ★ at bottom of this post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)

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

    Re: Index & Match Help for date lookup

    1. Reverse the order of the table in Date & week (ascending).

    2. Demerge the date cells in Wk 01 row 5.

    3. Use this formula in D5:

    =IF(MOD((COLUMNS($D:D)-1),3)=0,INDEX(Date_Week[[Date]:[Date]],MATCH(1,INDEX((Date_Week[[Week]:[Week]]=$D$3+0)*(Date_Week[[Year]:[Year]]=$D$4),0),0)+INT((COLUMNS($D:D)-1)/3)),"")

    drag across.

    4. In D6: =TEXT(D5,"dddd") copied across.

    5. if you REALLY want to you can now individually remerge the sets of 3 cells in row 5. I despise merged cells.... so have left you to do that.

    I cannot seem to be able to upload your file again. I'll try again later.

  6. #6
    Registered User
    Join Date
    04-30-2019
    Location
    Stoke-on-Trent, England
    MS-Off Ver
    2016
    Posts
    21

    Re: Index & Match Help for date lookup

    Thank you shukla.ankur281190 that was great he only thing i had to change was with the aecond formula, it gave me fridays date when put in d5 so i just counted backwards starting with 7 down to 1

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

    Re: Index & Match Help for date lookup

    Glad you got sorted!! there's something weird with your file. Over here, it bloated to 2.55 Mb and I can't reduce the filesize back to normal. It keeps adding in 1,000,000 rows on the first sheet.

  8. #8
    Registered User
    Join Date
    04-30-2019
    Location
    Stoke-on-Trent, England
    MS-Off Ver
    2016
    Posts
    21
    Thanks for your help also Glenn i have tried your way too and got both working, i too hate merged cells but i am trying to make this sheet as easy and tidy as possible for others to use. Not sure why it bloated that big even with adding in the rest of the 52 tabs for the weeks its only a few hundred kb here
    Quote Originally Posted by Glenn Kennedy View Post
    Glad you got sorted!! there's something weird with your file. Over here, it bloated to 2.55 Mb and I can't reduce the filesize back to normal. It keeps adding in 1,000,000 rows on the first sheet.

+ 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. Replies: 7
    Last Post: 04-03-2019, 05:00 PM
  2. Add a date lookup to index Match formula
    By Just_Hooch in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 08-16-2018, 09:37 AM
  3. Index + Match + Lookup -- return next largest date
    By bgoodsell in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-30-2015, 05:48 PM
  4. [SOLVED] Match-Index in stead of Index-Match lookup Array among Arrays
    By Numnum in forum Excel General
    Replies: 2
    Last Post: 10-15-2015, 02:08 PM
  5. Replies: 6
    Last Post: 04-30-2014, 02:42 AM
  6. Match/Index/Lookup - Searching From Bottom to Top (A reverse lookup maybe)
    By Neutralizer in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-02-2013, 03:55 AM
  7. Replies: 7
    Last Post: 06-19-2011, 12:51 PM

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