VBA SumIF
Hi Jennifer,
Basic SUMIF in VBA is
myVal = Application.sumif(range("A1:A10"),"a",range("b1:b1 0"))
Then yoiu just replace tyhe test value for the combo value
myVal = Application.sumif(range("A1:A10"),cboInvoice.Value , range("b1:b10"))
You then might want to test there are no errors
If IsError(myVal) Then
MsgBox "error"
End If
--
HTH
Bob Phillips
"Jennifer" wrote in message
...
Can I just say I am truelly learning Excel is never ending! This project
started rather modest. Ha!
Ok- I have a userform it displays an invoice # via cbobox. How do I have a
label on the form that looks at that invoice # goes to the producedata
worksheeet and does a sumif of the boxes sold. Thank you!
--
Though daily learning, I LOVE EXCEL!
Jennifer
|