Option
Explicit
Public
Sub
test()
Dim
objCell
As
Range
Dim
avntArray1()
As
Variant
, avntArray2()
As
Variant
Dim
strOutput
As
String
For
Each
objCell
In
Range(Cells(1, 1), Cells(Cells(Rows.Count, 1).
End
(xlUp).Row, 1))
With
objCell
avntArray1 = Range(Cells(.Row, 3), Cells(.Row, Cells(.Row, Columns.Count).
End
(xlToLeft).Column)).Value
With
WorksheetFunction
avntArray2 = .Transpose(.Transpose(avntArray1))
End
With
strOutput =
"["
& Join$(SourceArray:=avntArray2, Delimiter:=
","
) &
"]"
Cells(.Row, 2).Value = strOutput
End
With
Next
End
Sub