how to use a variable for the criteria in a sumif function?

D

Dick B.

I am trying to use a named variable for the criteria in a sumif function.
=sumif(A1:A4,"currentjobno",B1:B4)
currentjobno has a value of 38006
 
I

Ian P

I didn't think it was possible to define a variable in "just" Excel. I
thought this had to be do in VB. If I've got it wrong then how do you define
variables in Excel?

Thanks

Ian
 
E

Elkar

I'm assuming he's referring to a single cell as a named range, rather than a
variable. Although the effect is very similar.
 
I

Ian P

Thanks, for a moment I thought a whole new area of Excel was going to open
up, much the same as when I first found out that it was possible to use VB in
worksheets.

Ian
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top