sumif(indirect >issue (syntax)

bluepenink

Well-known Member
Joined
Dec 21, 2010
Messages
585
hello all

having some trouble placeing the "" or syntax portion...i keep getting the error "too many arguments"....

here is my formula

=SUMIF(INDIRECT("'"&$C$3&"'!"&$A$2:$A$54,F$1,INDEX(INDIRECT("'"&$C$3&"'!"&$C$2:$X$54,0,MATCH($C48,INDIRECT("'"&$C$3&"'!"&$C$1:$X$1,0))))))

basically, $C$3 = person's name aka worksheet name, so i have a drop down menu, so when C3 changes, i want the name to look off the worksheet


here is my original formula, prior to placing the indirect
=SUMIF('Milwaukee (SE&ISE) Data'!$A$2:$A$54,'Milwaukee (2)'!F$1,INDEX('Milwaukee (SE&ISE) Data'!$C$2:$X$54,0,MATCH($C48,'Milwaukee (SE&ISE) Data'!$C$1:$X$1,0)))

im trying to change that

'Milwaukee (SE&ISE) Data'! .........with $C$3

can someone pls help!

thx u
 
Last edited:

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Try...

=SUMIF(INDIRECT("'"&$C$3&"'!A2:A54"),INDIRECT("'"&$C$3&"'!F1"),INDEX(INDIRECT("'"&$C$3&"'!C2:X54"),0,MATCH(C48,INDIRECT("'"&$C$3&"'!C1:X1"),0)))
 
Upvote 0
hello F$1 is in the same workbook...(and my excel is busy calculating) so before i try to code...is it ok if i use it in the following method

=SUMIF(INDIRECT("'"&$C$3&"'!A2:A54"),F$1,INDEX(INDIRECT("'"&$C$3&"'!C2:X54"),0,MATCH(C48,INDIRECT("'"&$C$3&"'!C1:X1"),0)))

i changed it to F$1

thx u so much.
 
Upvote 0
hello all

having some trouble placeing the "" or syntax portion...i keep getting the error "too many arguments"....

here is my formula

=SUMIF(INDIRECT("'"&$C$3&"'!"&$A$2:$A$54,F$1,INDEX(INDIRECT("'"&$C$3&"'!"&$C$2:$X$54,0,MATCH($C48,INDIRECT("'"&$C$3&"'!"&$C$1:$X$1,0))))))

basically, $C$3 = person's name aka worksheet name, so i have a drop down menu, so when C3 changes, i want the name to look off the worksheet


here is my original formula, prior to placing the indirect
=SUMIF('Milwaukee (SE&ISE) Data'!$A$2:$A$54,'Milwaukee (2)'!F$1,INDEX('Milwaukee (SE&ISE) Data'!$C$2:$X$54,0,MATCH($C48,'Milwaukee (SE&ISE) Data'!$C$1:$X$1,0)))

im trying to change that

'Milwaukee (SE&ISE) Data'! .........with $C$3

can someone pls help!

thx u
It sshould be:
Code:
=SUMIF(INDIRECT("'"&$C$3&"'!$A$2:$A$54"),F$1,
    INDEX(INDIRECT("'"&$C$3&"'!$C$2:$X$54"),0,
      MATCH($C48,INDIRECT("'"&$C$3&"'!$C$1:$X$1"),0)))
 
Upvote 0
Hello

thx u for your help.

for some odd reason, it;s giving me a #N/A error?

i cant seem to understanding why. using my original formula, for milwaukee, it's now looking for a sheet called i.e. "John Doe" in C3...but returning a #N/A. the formatting and layout is the exact same as the milwaukee sheet?

any ideas? thx u guys!
 
Upvote 0
First, just in case you're using the formula I offered, the column reference for cell C48 should have been an absolute reference. Therefore, C48 should have been $C48.

If you're still getting an error, what values do C48 and C1:X1 contain?
 
Upvote 0
hello guys
thx u so much...it was suppose to change it o B1-X1 instead of C1, thx u so much once again, superb help!!

u guys are the best!!!! cheers
 
Upvote 0
Hello

thx u for your help.

for some odd reason, it;s giving me a #N/A error?

i cant seem to understanding why. using my original formula, for milwaukee, it's now looking for a sheet called i.e. "John Doe" in C3...but returning a #N/A. the formatting and layout is the exact same as the milwaukee sheet?

any ideas? thx u guys!

If C3 houses John Doe and there is a sheet of that name, the formula should work. By the way, I took C3, C48, and F1 to be cells in the sheet from within the formula is invoked.
 
Upvote 0

Forum statistics

Threads
1,224,521
Messages
6,179,291
Members
452,902
Latest member
Knuddeluff

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top