+ Reply to Thread
Results 1 to 3 of 3

Prefix number with '

  1. #1
    Registered User
    Join Date
    02-24-2010
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    10

    Prefix number with '

    I posted a question a few weeks ago and a solution was found and some great code was written by JBeaucaire and others. I now just need to enhance the maco a little and have the result prefixed with a '




    Please Login or Register  to view this content.
    The macro works just fine and rounds a number to 2 decimal places but I need the resulting numberto be prefixed with a '

    Eg at the moment

    100.5346666 would become 100.53 and what i want to do is have it '100.53


    I had tried the following

    Please Login or Register  to view this content.
    But with out any luck

    So Any help on this issue would be great ;-)

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Prefix number with '

    Please Login or Register  to view this content.
    Entia non sunt multiplicanda sine necessitate

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

    Re: Prefix number with '

    And for the sake of demo'ing the Eval method:

    Please Login or Register  to view this content.
    if you want the apostrophe as opposed to just storing as text - remove the NumberFormat line and use ""'""&ROUND(...)
    Last edited by DonkeyOte; 03-10-2010 at 03:51 AM. Reason: added note re: '

+ 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