+ Reply to Thread
Results 1 to 3 of 3

Comma separate keywords

Hybrid View

  1. #1
    Registered User
    Join Date
    08-10-2007
    Posts
    5

    Comma separate keywords

    Hi All

    Any possible way I can use Excel to take a list of keywords in a vertical list, such as...

    car
    boat
    tree
    van
    dog
    cat
    etc

    Get it to insert commas behind each keyword...

    car,
    boat,
    tree,
    van,
    dog,
    cat,
    etc,

    Then enable me to extract in the following way...

    car, boat, tree, van, dog, cat, etc,

    Any help would be grately appreciated.

    Cheers

    Todd

  2. #2
    Forum Contributor
    Join Date
    12-12-2005
    Posts
    667
    One easy way would be to tonvert it to a csv file that you couls import:
    Sub Macro1()
    '
    ' Macro1 Macro
    '
    
    '
        Range("A1:A6").Select
        Selection.Copy
        Range("B1").Select
        Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
            False, Transpose:=True
        Application.CutCopyMode = False
        Range("B1:G1").Cut Destination:=Range("A1:F1")
        Range("A2:A6").Select
        Selection.ClearContents
        Range("A1").Select
        ActiveWorkbook.SaveAs Filename:="C:\Book1.csv" _
            , FileFormat:=xlCSV, CreateBackup:=False
    End Sub
    Best regards,

    Ray

  3. #3
    Registered User
    Join Date
    08-10-2007
    Posts
    5

    Thanks

    Hi Ray

    I'm very, very new to Excel, and I have no idea how to use what you gave me, but, I'll do my best to figure it out.

    Thank you kindly for shining light on this for me!

    Todd



    Quote Originally Posted by raypayette
    One easy way would be to tonvert it to a csv file that you couls import:
    Sub Macro1()
    '
    ' Macro1 Macro
    '
    
    '
        Range("A1:A6").Select
        Selection.Copy
        Range("B1").Select
        Selection.PasteSpecial Paste:=xlPasteAll, Operation:=xlNone, SkipBlanks:= _
            False, Transpose:=True
        Application.CutCopyMode = False
        Range("B1:G1").Cut Destination:=Range("A1:F1")
        Range("A2:A6").Select
        Selection.ClearContents
        Range("A1").Select
        ActiveWorkbook.SaveAs Filename:="C:\Book1.csv" _
            , FileFormat:=xlCSV, CreateBackup:=False
    End Sub

+ 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