Evaluate or WorksheetFunction Problem

  • Thread starter Thread starter SowBelly
  • Start date Start date
S

SowBelly

Hello:

I have the following SUMPRODUCT formula in a worksheet cell:

=SUMPRODUCT((MYSHEET!$P$12:$P$999="RR")*(MYSHEET!$V$12:$V$999<>"OPEN")*(MYSHEET!$AL$12:$AL$999))

I am trying to recreate this formula in VBA using the Evaluate or
WorksheetFunction feature, but am running into problems. How can I
recreate this formula in VBA.

"Pigs can't be humans, but humans can be Pigs!"

Eating at the trough of life.

Oink!

SowBelly
 
Using Excel 2002,

Evaluate("SUMPRODUCT((MYSHEET!$P$12:$P$999=""RR"")*(MYSHEET!$V$12:$V$999<>""OPEN"")*(MYSHEET!$AL$12:$AL$999))")

works for me. Maybe you weren't using the double double-quotes ("") to
indicate the " character within the string.
 

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

Back
Top