+ Reply to Thread
Results 1 to 6 of 6

Adding Quotation marks to populated fields

  1. #1
    Registered User
    Join Date
    04-17-2006
    Posts
    40

    Adding Quotation marks to populated fields

    Hi! I have a spreadsheet with a bunch of columns (A, B, C, D etc.) each column has 421 fields. In each field is a unique 8-digit number.

    Now, I need to take the numbers in the fields under Column C and put quotation marks around them, basically turning this:

    12345686
    32165482
    15659875
    12546586

    into this:

    "12345686"
    "32165482"
    "15659875"
    "12546586"

    Any advice on how to do this? Thanks!

    BTW - This will be converted to a .csv file for use in a program called Invoice Express - nothing screwy is going to happen to my quotes once I save the .xls file as a .csv file, right? Guys...? Right guys...?
    Last edited by pentatonic145; 04-17-2006 at 04:17 PM.

  2. #2
    Bob Phillips
    Guest

    Re: Adding Quotation marks to populated fields


    For i =1 To Cells(Rows.Count,"C").End(xlUp).Row
    Cells(i,"C").Value = """ & Cells(i,"C").Value & """
    Next i

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    "pentatonic145" <pentatonic145.26fd2m_1145304602.8901@excelforum-nospam.com>
    wrote in message
    news:pentatonic145.26fd2m_1145304602.8901@excelforum-nospam.com...
    >
    > Hi! I have a spreadsheet with a bunch of columns (A, B, C, D etc.) each
    > column has 421 fields. In each field is a unique 8-digit number.
    >
    > Now, I need to take the numbers in the fields under Column C and put
    > quotation marks around them, basically turning this:
    >
    > 12345686
    > 32165482
    > 15659875
    > 12546586
    >
    > into this:
    >
    > "12345686"
    > "32165482"
    > "15659875"
    > "12546586"
    >
    > But HOW man, how does I doing that mang?
    >
    > Please for helping to me - thnaks!
    >
    >
    > --
    > pentatonic145
    > ------------------------------------------------------------------------
    > pentatonic145's Profile:

    http://www.excelforum.com/member.php...o&userid=33575
    > View this thread: http://www.excelforum.com/showthread...hreadid=533521
    >




  3. #3
    ANdras
    Guest

    RE: Adding Quotation marks to populated fields

    Hi there,

    you can do it in a helping-column, like this:
    =""""&C1&"""" <= 4 times " both, before and after
    then copy downwards the formula and if you want to replace it to column C,
    then ctrl + c and then paste/special/values

    Any good?
    Best regards,
    ANdras
    (Hungary)

    "pentatonic145" wrote:

    >
    > Hi! I have a spreadsheet with a bunch of columns (A, B, C, D etc.) each
    > column has 421 fields. In each field is a unique 8-digit number.
    >
    > Now, I need to take the numbers in the fields under Column C and put
    > quotation marks around them, basically turning this:
    >
    > 12345686
    > 32165482
    > 15659875
    > 12546586
    >
    > into this:
    >
    > "12345686"
    > "32165482"
    > "15659875"
    > "12546586"
    >
    > But HOW man, how does I doing that mang?
    >
    > Please for helping to me - thnaks!
    >
    >
    > --
    > pentatonic145
    > ------------------------------------------------------------------------
    > pentatonic145's Profile: http://www.excelforum.com/member.php...o&userid=33575
    > View this thread: http://www.excelforum.com/showthread...hreadid=533521
    >
    >


  4. #4
    Registered User
    Join Date
    04-17-2006
    Posts
    40
    We are trying out this formula:

    To take the data in cell C2 and put quotes around it, we are trying this:

    =""""&C2&""""&""

    and it works!

    BUT - we have to do the same thing now with column D, which contains dates in this format: mm/dd/yyyy

    When I apply that same formula to cell D2, which contains the data:

    04/12/2005

    it renders this:

    "38454"

    and I can't get it to convert back to mm/dd/yyy format! :-(

    My goal is to get D2 (and D3 and D4 and all the other dates in column D) to look like this:

    "04/12/2005" ???

  5. #5
    Peo Sjoblom
    Guest

    Re: Adding Quotation marks to populated fields

    =""""&TEXT(D2,"mm/dd/yyyy")&""""&""


    --

    Regards,

    Peo Sjoblom

    http://nwexcelsolutions.com



    "pentatonic145" <pentatonic145.26fhgy_1145310300.5708@excelforum-nospam.com>
    wrote in message
    news:pentatonic145.26fhgy_1145310300.5708@excelforum-nospam.com...
    >
    > We are trying out this formula:
    >
    > To take the data in cell C2 and put quotes around it, we are trying
    > this:
    >
    > =""""&C2&""""&""
    >
    > and it works!
    >
    > BUT - we have to do the same thing now with column D, which contains
    > dates in this format: mm/dd/yyyy
    >
    > When I apply that same formula to cell D2, which contains the data:
    >
    > 04/12/2005
    >
    > it renders this:
    >
    > "38454"
    >
    > and I can't get it to convert back to mm/dd/yyy format! :-(
    >
    > My goal is to get D2 (and D3 and D4 and all the other dates in column
    > D) to look like this:
    >
    > "04/12/2005" ???
    >
    >
    > --
    > pentatonic145
    > ------------------------------------------------------------------------
    > pentatonic145's Profile:
    > http://www.excelforum.com/member.php...o&userid=33575
    > View this thread: http://www.excelforum.com/showthread...hreadid=533521
    >




  6. #6
    Registered User
    Join Date
    04-17-2006
    Posts
    40
    Peo - That did it my friend! Thank you!

+ 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