+ Reply to Thread
Results 1 to 4 of 4

INDIRECT FORMULA AUTOMATE, other then just YEAR (YYYY)

  1. #1
    Registered User
    Join Date
    11-01-2021
    Location
    Hull, England
    MS-Off Ver
    2021
    Posts
    40

    INDIRECT FORMULA AUTOMATE, other then just YEAR (YYYY)

    Hello, sample file attached.


    My question is FORMULA to automate from TAB NAME in COLUMN A of 2ND TAB (EV YEAR TOTAL), which I have done successfully per Tab Name per YEAR columns B to P, but I want more creative tab names then just YEAR, and will have to use to call TABS year (So auto date criteria still works) + description within same workbook.

    SPREADSHEETs are EV (ELEC VEHICLE) charge/cost/miles summary PER YEAR & SUMMARY YEARS TABS:

    2040 & EV2041.

    TABs are identical except Name.


    2nd Tab is SUMMARY TAB (EV YEAR TOTAL) uses INDEX FORMULA:


    * YEAR ONLY EXAMPLE (ROW4): This Formula works as intended when Tab Name is formatted as YEAR only.

    A4 Format Cells, Custom, YYYY


    COL B: =IF($A4<=$Z$2,INDIRECT("'"&YEAR($A$4)&"'!A$225"),"")

    COL C: =IF($A4<=$Z$2,INDIRECT(TEXT($A4,"yyyy")&"!$B$225"),"")




    * DESCRIPTION + YEAR EXAMPLE (ROW5): Also A5 Format Cells, Custom, "EV"YYYY.

    Date display relevant results still work, but as you can see from ROW5 COLUMNS C onwards data is not presented as Formula needs correct edit for more complicated TAB name then basic YEAR only.


    COL B: =IF($A5<=$Z$2,INDIRECT("'"&YEAR($A$4)&"'!A$225"),"")

    COL C: =IF($A5<=$Z$2,INDIRECT(TEXT($A5,"yyyy")&"!$B$225"),"")



    Q. Hence what is Formula for TAB NAME REF when other then just YEAR (YYYY)?

    For example EV2041 (So date IF Formula still works)

    Hence Formula method to support numbers/letters/spaces.


    EV photo.png

    Cheers


    Stephan
    Attached Files Attached Files
    Last edited by StephanRS; 03-12-2023 at 08:04 PM.

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2504
    Posts
    13,638

    Re: INDIRECT FORMULA AUTOMATE, other then just YEAR (YYYY)

    Are you still using XL2003 as stated in your profile? If not, amend your profile accordingly as answers are tailored to the OP's version. Thx

  3. #3
    Registered User
    Join Date
    11-01-2021
    Location
    Hull, England
    MS-Off Ver
    2021
    Posts
    40

    Re: INDIRECT FORMULA AUTOMATE, other then just YEAR (YYYY)

    Hello.

    Excel 2003.

    or

    Excel 2021 Formulas.

    Just prefer Xls as menu simple layout & not hidden either!

    Cheers
    Last edited by StephanRS; 03-12-2023 at 06:50 PM.

  4. #4
    Registered User
    Join Date
    11-01-2021
    Location
    Hull, England
    MS-Off Ver
    2021
    Posts
    40

    Re: INDIRECT FORMULA AUTOMATE, other then just YEAR (YYYY)

    Hello


    Solved it myself, 2 versions attached, both 3D Indirect Tabs summary, 1 using YEAR date TAB names only, and the other using Alphanumberic TAB names. It was some simple formula edit in the end, Text General instead of Year, as I originally asked.

    See formulas in EV YEAR TOTAL rows B2:P12, for differences between the 2 versions:

    ALPHANUMBERIC TAB TYPE:
    B2 =IF(AND(B$15="YES"),IF($AF2<=$AB$1,INDIRECT("'"&TEXT($A2,"General")&"'!A$225"),""))
    C2 =IF(AND(C$15="YES"),IF($AF2<=$AB$1,INDIRECT(TEXT($A2,"yyyy")&"!$B$225"),""))

    EV ALPHANUMERIC.png

    Alphanumeric 3D Indirect Tabs, fixed with few helper columns for Column A2:A12 using Value & Date (AE2:AF12).
    AE2 =VALUE(RIGHT(A2,4))
    AF2 =DATE(AE2,1,1)

    Both files have DATE pre check, that I've set in EV YEAR TOTAL (summary tab) cell AB1.

    YEAR TAB TYPE:
    B2 =IF(AND(B$15="YES"),IF($A2<=$AB$1,INDIRECT("'"&YEAR($A2)&"'!A$225"),""))
    C2 =IF(AND(C$15="YES"),IF($A2<=$AB$1,INDIRECT(TEXT($A2,"yyyy")&"!$B$225"),""))

    EV TAB.png

    I know I'm impressed!

    Stephan

+ 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] Formula to extract day.month and year in format dd/mm/yyyy
    By Howardc1001 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-16-2021, 11:27 AM
  2. Replies: 4
    Last Post: 02-22-2017, 07:55 PM
  3. Help require to change a year format to custom yyyy-yyyy format
    By mso3 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 02-23-2015, 01:04 AM
  4. [SOLVED] Need date formula to convert mm-dd-yyyy or mm/dd/yyyy to dd-mm-yyyy in 1 formula
    By ChristopherH in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 01-29-2014, 09:07 AM
  5. [SOLVED] Formula TEXT returns "yyyy" instead of the real year number
    By Hitch75 in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 10-28-2013, 06:57 AM
  6. [SOLVED] Need a formula to automate an Indirect Cell Validation
    By jrtulare185 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-11-2012, 01:42 PM
  7. Copy+Paste macro dd/mm/yyyy to dd/mm/yyyy and NOT dd/mm/yyyy to mm/dd/yyyy
    By uimhirADo in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-08-2012, 03:45 AM

Tags for this Thread

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