LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 25
Default Split up or delineate data

try:

Dim myStr As String
Dim varData As Variant

myStr = "ant,antique,art,bee,beautiful,bored,chores,dancin g,daytime"
varData = Split(myStr, ",")
Range("A1").Resize(UBound(varData) + 1) = Application.Transpose(varData)

That basically just copied the string into column A. What I meant was, I was also thinking about a solution that doesn't involve spreadsheet cells.

For example, if

myStr = "ant,antique,art,bee,beautiful,bored,chores,dancin g,daytime"

then the output should be:

myStr2 = "--A--,ant,antique,art,--B--,bee, etc.."

But, I'm happy with your initial solution.

Thanks!


 
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
split data swati Excel Discussion (Misc queries) 3 August 7th 07 10:46 AM
I'm Lost... Bin? Delineate different processes with time samples William Elerding Excel Programming 5 August 10th 06 06:39 AM
Split data and copy surrounding data dee Excel Programming 5 July 19th 06 01:23 PM
Split data into new sheets bernard Excel Discussion (Misc queries) 4 January 4th 06 04:45 PM
how to split data into columns and arrange the resulting data jack Excel Discussion (Misc queries) 1 November 11th 05 11:20 PM


All times are GMT +1. The time now is 08:53 AM.

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"