I need to calculate the percentage for the below code.
Cell AE43 gives the total count out.
Cell AE51 gives valid count.
Cell AE53 should hold the % for this.
How do i implement this sub for multiple cells without creating separate sub for each cells?
Sub WBR()
Dim Count1Criteria As Variant
Dim Count3Criteria As Variant
Dim test As Variant
Dim wf As WorksheetFunction
Set wf = Application.WorksheetFunction
Filter1InSummary = Array(Array("AE4", "Latency", "O:O", "Pass"), _
Array("AE51", "TT", "G:G", "Yes"), _
Array("AE52", "TT", "G:G", "No"), _
Array("AE61", "Reactive", "R:R", "Item"))
Filter3InSummary = Array(Array("AE43", "TT", "I:I", "<>Duplicate TT", _
"G:G", "<>Not Tested", _
"U:U", "Item"))
For Each test In Filter3InSummary
With Worksheets(test(1))
Range(test(0)) = wf.CountIfs(.Range(test(2)), test(3), _
.Range(test(4)), test(5), _
.Range(test(6)), test(7))
End With
Next
Bookmarks