+ Reply to Thread
Results 1 to 5 of 5

Excel argument is too long. What should I do?

  1. #1
    Registered User
    Join Date
    07-11-2012
    Location
    Massachusetts,US
    MS-Off Ver
    Excel 2010
    Posts
    44

    Excel argument is too long. What should I do?

    =IF(AW3="January",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,2,FALSE),IF(AW3="February",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,3,FALSE),IF(AW3="March",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,4,FALSE),IF(AW3="April",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,5,FALSE),IF(AW3="May",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,6,FALSE),IF(AW3="June",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,7,FALSE),IF(AW3="July",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,8,FALSE),IF(AW3="August",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,9,FALSE),IF(AW3="September",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,10,FALSE,IF(AW3="October",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,11,FALSE),IF(AW3="November",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,12,FALSE),IF(AW3="December",VLOOKUP(TRIM(AH3),'Average Price'!$A$1:$M$291,13,FALSE),))))))))))

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

    Re: Excel argument is too long. What should I do?

    Are the contents of AW3 plain text , not dates formatted to show months ?

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Excel argument is too long. What should I do?

    Maybe ...

    =VLOOKUP(TRIM(AH3), 'Average Price'!$A$1:$M$291, MONTH(1 & AW3) + 1, FALSE)
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    07-11-2012
    Location
    Massachusetts,US
    MS-Off Ver
    Excel 2010
    Posts
    44

    Re: Excel argument is too long. What should I do?

    I have defined the months so January = 1 feb=2 and so on...... and aw3 is the month in text form

  5. #5
    Registered User
    Join Date
    07-11-2012
    Location
    Massachusetts,US
    MS-Off Ver
    Excel 2010
    Posts
    44

    Re: Excel argument is too long. What should I do?

    Thank You it worked great can you explain the last part of the formula to me "MONTH(1 & AW3) + 1, FALSE".
    Quote Originally Posted by shg View Post
    Maybe ...

    =VLOOKUP(TRIM(AH3), 'Average Price'!$A$1:$M$291, MONTH(1 & AW3) + 1, FALSE)

  6. #6
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Excel argument is too long. What should I do?

    Month("1September") returns 9.

    The FALSE is the same as in your original formula.

+ 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