nick_clarke
New Member
- Joined
- Aug 26, 2010
- Messages
- 27
Hi
I've recently transferred some working vba code from one spreadhseet to another, changing the cell references only to correspond to the new spreadsheet.
The code returns a type 13 mismatch error when I try to run it in the new spreadsheet. It uses evaluate and sumproduct, and I have verified the sumproduct works by entering the formula into a cell.
Below is the code:
e1 = Evaluate("=SUMPRODUCT(('Active Case Tracker'!$T$3:$T$15998>" & twka & " )*('Active Case Tracker'!$T$3:$T$15998<=" & twkb & ")*('Active Case Tracker'!$T$3:$T$15998>'Active Case Tracker'!$Z$3:$Z$15998)*('Active Case Tracker'!$AE$3:$AE$15998=""No Change Of Outcome"")*('Active Case Tracker'!$X$3:$X$15998=""N/A""))")
e1 is a variable that I have declared as an integer, as this was how it was declared in the code for the working spreadsheet.
Any ideas on why I am getting the error message?
My head is starting to hurt from banging it against my desk, any help would be much appreciated.
Thanks
I've recently transferred some working vba code from one spreadhseet to another, changing the cell references only to correspond to the new spreadsheet.
The code returns a type 13 mismatch error when I try to run it in the new spreadsheet. It uses evaluate and sumproduct, and I have verified the sumproduct works by entering the formula into a cell.
Below is the code:
e1 = Evaluate("=SUMPRODUCT(('Active Case Tracker'!$T$3:$T$15998>" & twka & " )*('Active Case Tracker'!$T$3:$T$15998<=" & twkb & ")*('Active Case Tracker'!$T$3:$T$15998>'Active Case Tracker'!$Z$3:$Z$15998)*('Active Case Tracker'!$AE$3:$AE$15998=""No Change Of Outcome"")*('Active Case Tracker'!$X$3:$X$15998=""N/A""))")
e1 is a variable that I have declared as an integer, as this was how it was declared in the code for the working spreadsheet.
Any ideas on why I am getting the error message?
My head is starting to hurt from banging it against my desk, any help would be much appreciated.
Thanks