+ Reply to Thread
Results 1 to 2 of 2

Text to rows?

  1. #1
    Registered User
    Join Date
    03-08-2006
    Posts
    3

    Text to rows?

    Hi,

    I have some comma delimited data that I have got in excel. There are 74 cells and in each cell there are several hundred comma delimited numbers. I have tried to use the "Text to columns" option (under the data menu) to get the comma delimited numbers into cells but if I do this I lose the last bit of the data as there are more comma delimited items in each cell than there are columns in the worksheet (only 256 columns in worksheet). What I need is a "Text to rows" option but I can't find this.

    Does anyone have any suggestions?

    Cheers,
    Laudrup

  2. #2
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Response

    This can be done by macro

    Sub Test()
    Open "C:\myCSVFile.csv" For Input As #1 'change as required
    Do While Not EOF(1)
    Line Input #1, FileLine
    Counter = Counter + 1
    X = Split(FileLine, ",")
    For N = 0 To UBound(X)
    Cells(N + 1, Counter) = X(N)
    Next N
    Loop
    Close #1
    End Sub
    Martin

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1