Thanks Thanks:  0
Likes Likes:  0
Results 1 to 4 of 4

Thread: Minus signs at end of cell

  1. #1
    New Member
    Join Date
    Apr 2002
    Posts
    4
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I have a sheet imported from a mainframe which shows minus signs at the end of the cell instead of the beginning in each cell where the value is minus.
    How can I correct this

  2. #2
    MrExcel MVP Ivan F Moala's Avatar
    Join Date
    Feb 2002
    Location
    Auckland, New Zealand
    Posts
    4,209
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On 2002-04-26 03:58, jnaylor wrote:
    I have a sheet imported from a mainframe which shows minus signs at the end of the cell instead of the beginning in each cell where the value is minus.
    How can I correct this
    Rather then recreating the wheel have a look
    @ Aarons site....Look here for the file.


    http://www.xl-logic.com/xl_files/vba/dash_masher.zip
    Kind Regards,
    Ivan F Moala From the City of Sails

  3. #3
    MrExcel MVP Jay Petrulis's Avatar
    Join Date
    Mar 2002
    Location
    Chicago, IL USA
    Posts
    2,040
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hi,

    Didn't download the file from Aaron's site (which is nice), so apologies if this is the same.

    Select your range (or modify the routine to find the range) and run this:

    Sub test()
    Dim c As Range
    For Each c In Selection
    If Not c.HasFormula And IsNumeric(c) Then c = CDbl(c)
    Next c
    End Sub

  4. #4
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Austin, Texas USA
    Posts
    11,654
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    =IF(RIGHT(A1)="-",-LEFT(A1,LEN(A1)-1),A1)

    [ This Message was edited by: Mark W. on 2002-04-26 06:51 ]

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •