Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 493
Default Converting CSV text in a single column, into multiple columns

One way (manually):

Select your column. Choose Data/Text to columns... Select the
Delimited radio button. Click Next. check the Comma checkbox. Click
next. Put $B$1 in the destination box. click finish.


One way (macro):

Public Sub ParseCSV()
With Selection
.TextToColumns Destination:=.Offset(0, 1), _
DataType:=xlDelimited, _
TextQualifier:=xlDoubleQuote, _
ConsecutiveDelimiter:=False, _
Tab:=False, _
Semicolon:=False, _
Comma:=True, _
Space:=False, _
Other:=False
End With
End Sub

Select the strings to convert (one column at a time) and run the
macro.


In article ,
"Kerry M. Soileau" wrote:

I've got string data in the first (A) column of a spreadsheet. Each string
consists of comma separated substrings. I'd like to distribute the
substrings out into their own columns, e.g., if An contains
"hi,there,my,name,is", I'd like to put "hi" into Bn, "there" into Cn, "my"
into Dn,"name" into En,"is" into Fn. It is easy to do this manually, but
when I use the Macro Recorder to get the code to do it, the code doesn't
work. Can anyone help?
Thanks,
Kerry Soileau


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Splitting Text from single cell in column across multiple Columns Harold Excel Worksheet Functions 3 March 14th 10 11:06 AM
Create single column from multiple columns. TraciAnn via OfficeKB.com Excel Discussion (Misc queries) 1 May 18th 09 06:19 PM
Critical - Converting Single Column Address Data into Multiple Col A.J. Excel Worksheet Functions 2 July 10th 08 06:39 PM
How do I convert multiple columns to a single column? scottflinders Excel Discussion (Misc queries) 5 November 12th 06 02:13 PM
Single column into multiple columns Heidi Excel Discussion (Misc queries) 3 November 1st 06 09:27 PM


All times are GMT +1. The time now is 05:30 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"