excel comma quote
Does this get you started:
Sub Test()
Dim i As Integer
Dim strList As String
For i = 1 To Range("MyRange").Count
strList = strList & """" & Range("MyRange")(i).Text & """, "
Next i
strList = Left(strList, Len(strList) - 2)
MsgBox strList
End Sub
I tested this on your short list and it produced the correct string.
However there may be a limit to the length of the string (max number of
characters)
Don't know if this will work for you.
" wrote:
Is there a way to select a column of ID numbers in an Excel (2002)
column and save it to a text file or clipboard with comma quote
delimiters?
0000031814
0000044857
0000015098
0000043186
0000111012
0000017184
becomes
"0000031814","0000044857","0000015098",
"0000043186","0000111012","0000017184"
|