Variable number of parameters : ParamArray « Language Basics « VBA / Excel / Access / Word






Variable number of parameters

 
Function sum(ParamArray x())
  Dim var
  For Each var In x()
    sum = sum + var
  Next var
End Function

 








Related examples in the same category