+ Reply to Thread
Results 1 to 4 of 4

Help With Arrays, real Basic Arrays

  1. #1
    Registered User
    Join Date
    05-15-2008
    Posts
    8

    Help With Arrays, real Basic Arrays

    I have this set up:

    =IF(H3-H9={0,1,2,3,4,5,6,7,8,9},{"I","N","T","Y","AE","AK","AQ","AV","BB","BG"},"INVALID DATE")

    If H3 and H9 are the same and equal 0, then the return is I

    However, If the H3 and H9 equals 1, the return is INVALID DATE. I want it to be N.

    What is this novice doing wrong?

  2. #2
    Valued Forum Contributor Richard Schollar's Avatar
    Join Date
    05-23-2006
    Location
    Hampshire UK
    MS-Off Ver
    Excel 2002
    Posts
    1,264
    Hi

    You need to use a lookup function for this eg:

    =IF(ISNA(VLOOKUP(H3-H9,{0,"I";1,"N";2,"T";3,"Y";4,"AE";5,"AK";6,"AQ";7,"AV";8,"BB";9,"BG"},2,0)),"INVALID DATE",VLOOKUP(H3-H9,{0,"I";1,"N";2,"T";3,"Y";4,"AE";5,"AK";6,"AQ";7,"AV";8,"BB";9,"BG"},2,0))

    Richard

  3. #3
    Registered User
    Join Date
    05-15-2008
    Posts
    8
    Wow. Complicated. I'll give it a try though. Thank you.

  4. #4
    Registered User
    Join Date
    05-15-2008
    Posts
    8
    Worked like a charm. This has helped me immensely. The user can now input a specific Worksheet, and a specific Year from that worksheet and get a pie chart of yearly oil usage.

    Fantastic! Thank you so much.

+ 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. Combination of arrays and comparing data
    By bgalaska in forum Excel General
    Replies: 0
    Last Post: 08-08-2008, 03:29 PM
  2. relationship between arrays
    By rodrigo.miramon in forum Excel General
    Replies: 2
    Last Post: 07-14-2008, 09:13 PM
  3. macros not updating in real time on LAN
    By nigelog in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-14-2007, 12:27 PM
  4. passing arrays to newly created chart module
    By BRay840 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-05-2007, 03:21 PM
  5. Replies: 2
    Last Post: 07-22-2007, 02:20 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