View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
L. Howard L. Howard is offline
external usenet poster
 
Posts: 852
Default Formula (or code) return the largest number of duplicates in a list.


Array entered, the formula works on the sheet.

=MAX(COUNTIF(A$1:A$200,A1:A200))


Trying to set the value to myMax in code errors on the word Countif

Dim myMax As Long
myMax = Application.WorksheetFunction = Max(CountIf("A$1:A$200", "A1:A200"))

Howard