+ Reply to Thread
Results 1 to 5 of 5

Can I keep those commas?

  1. #1
    Registered User
    Join Date
    04-19-2009
    Location
    London, England
    MS-Off Ver
    Excel 2002
    Posts
    4

    Can I keep those commas?

    I'm converting a text file with strings such as this into a form that can be read by another application.

    "2JC","0278294","JP Morgan Life UK Liquidity 3",E

    I need to get rid of the quotes characters but keep the data separated by the commas.

    As I open the txt file into Excel, the Text Import Wizard appears and recognizes the file as Delimited.

    I follow the steps and, at Step 2, I choose Comma as the delimiter.

    However, when I come to save the file as a TXT, the commas that separated the data have gone. (The Save As dialogue box only offers Text (Tab Delimited) as an option for Text files.)

    The application that I'm going to import into needs those commas to separate the various items of data.

    Is there a way to retain (or restore) the commas?

    Thanks.

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Can I keep those commas?

    You could save as .csv and then rename the file post save - altering extension from .csv to .txt

    Does that work for you ?

  3. #3
    Forum Contributor mubashir aziz's Avatar
    Join Date
    03-18-2009
    Location
    Lahore, Pakistan
    MS-Off Ver
    MS Office 2013
    Posts
    533

    Re: Can I keep those commas?

    Suppose your data is in 5 column A2,B2,C2,D2,E2,F2 ...... not put this formula in column G2...

    =A2&","&B2&","&C2&","&D2&","&E2&","&F2

  4. #4
    Registered User
    Join Date
    04-19-2009
    Location
    London, England
    MS-Off Ver
    Excel 2002
    Posts
    4

    Re: Can I keep those commas?

    Wow, you guys are too quick! I'd just figured it out and was coming back to delete my question!

    Am I dumb! Of course there is a CSV option in the Save-As dialogue - I just didn't notice it in there!

    I did find though, that I needed to go into the Properties of the saved file to tell it open with Notepad, rather than Excel. And there are mycommas!

    Thanks!

  5. #5
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Can I keep those commas?

    ...as I said if you rename the file post close from .csv to .txt it will automatically associate the file with Notepad.

+ 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