Skip to content

Instantly share code, notes, and snippets.

@snahor
Created April 22, 2016 01:08
Show Gist options
  • Save snahor/932908746f8927033ad227e4c1e17f76 to your computer and use it in GitHub Desktop.
Save snahor/932908746f8927033ad227e4c1e17f76 to your computer and use it in GitHub Desktop.
Function nameList(ParamArray xs() As Variant) As String
For i = LBound(xs) To UBound(xs)
For Each x In xs(i).Cells
If x.value <> "" Then
If nameList <> "" Then
nameList = nameList & ", "
End If
nameList = nameList & x.value
End If
Next x
Next i
End Function
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment