+ Reply to Thread
Results 1 to 6 of 6

Deleting all characters Right of a comma

  1. #1
    Forum Contributor
    Join Date
    02-05-2010
    Location
    Toronto, Ontario
    MS-Off Ver
    Excel 2003
    Posts
    113

    Deleting all characters Right of a comma

    Hi All,

    I'm using the following comma to delete all characters right of a comma... any ideas why it's not working?

    =LEFT(a1,FIND(“,”,A1)-1)
    Attached Files Attached Files
    Last edited by Zan03; 04-17-2010 at 09:21 AM.

  2. #2
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Deleting all characters Right of a comma

    those are the wrong "" you are using char148 " is char 34

    try
    =LEFT(A1,FIND(",",A1)-1)
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  3. #3
    Valued Forum Contributor mdbct's Avatar
    Join Date
    11-11-2005
    Location
    CT
    MS-Off Ver
    2003 & 2007
    Posts
    848

    Re: Deleting all characters Right of a comma

    I got an error due to the curly quotes.

    vs "

    try this one:
    Please Login or Register  to view this content.

  4. #4
    Forum Contributor
    Join Date
    02-05-2010
    Location
    Toronto, Ontario
    MS-Off Ver
    Excel 2003
    Posts
    113

    Re: Deleting all characters Right of a comma

    yeah, you're right... your code works perfectly... Thanks for the help!
    Quote Originally Posted by mdbct View Post
    I got an error due to the curly quotes.

    vs "

    try this one:
    Please Login or Register  to view this content.

  5. #5
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Deleting all characters Right of a comma

    mind you if you just want to delete everything to right of comma including the comma use find /replace
    find ,* replace with nothing

  6. #6
    Forum Contributor
    Join Date
    02-05-2010
    Location
    Toronto, Ontario
    MS-Off Ver
    Excel 2003
    Posts
    113

    Re: Deleting all characters Right of a comma

    Thanks Martin.. i've made a mental note.. hopefully it sticks around for next time i need it!

+ 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