+ Reply to Thread
Results 1 to 7 of 7

I want brackets around my math equation answer?

  1. #1
    Ms Serene
    Guest

    I want brackets around my math equation answer?

    I am putting together a equipment table that has to have entries in metric. I
    would like to set it up so that you type in the english units and it would
    the convert into metric on the next line. However i have to have Brackets
    around the Metric numbers...is there a way to do this?

  2. #2
    Forum Contributor VBA Noob's Avatar
    Join Date
    04-25-2006
    Location
    London, England
    MS-Off Ver
    xl03 & xl 07(Jan 09)
    Posts
    11,988
    How about this
    Converting 1 foot into (0.3048) mtrs

    ="("&A18*0.3048&")"

    VBA Noob

  3. #3
    Gord Dibben
    Guest

    Re: I want brackets around my math equation answer?

    You have failed to say which units you are working with but try this for inches
    to centimeters.

    In B1 enter =IF(A1="","",A1*2.54)

    Drag/copy down column B

    Format Column B to Custom (#,##0.00)

    An event code solution if you wanted would be as follows...............

    Private Sub Worksheet_Change(ByVal Target As Excel.Range)
    'when entering data in any cell in Col A
    On Error GoTo enditall
    Application.EnableEvents = False
    If Target.Cells.Column = 1 Then
    n = Target.Row
    If Excel.Range("A" & n).Value <> "" Then
    Excel.Range("B" & n).Value = Excel.Range("A" & n).Value * 2.54
    End If
    End If
    enditall:
    Application.EnableEvents = True
    End Sub

    Format Column B to Custom (#,##0.00)


    Gord Dibben MS Excel MVP


    On Tue, 25 Jul 2006 11:55:03 -0700, Ms Serene <Ms
    Serene@discussions.microsoft.com> wrote:

    >I am putting together a equipment table that has to have entries in metric. I
    >would like to set it up so that you type in the english units and it would
    >the convert into metric on the next line. However i have to have Brackets
    >around the Metric numbers...is there a way to do this?



  4. #4
    Martin P
    Guest

    RE: I want brackets around my math equation answer?

    If you have feet in A1, to convert to metres in A2:
    ="("&CONVERT(A1,"ft","m")&")"

    "Ms Serene" wrote:

    > I am putting together a equipment table that has to have entries in metric. I
    > would like to set it up so that you type in the english units and it would
    > the convert into metric on the next line. However i have to have Brackets
    > around the Metric numbers...is there a way to do this?


  5. #5
    Ms Serene
    Guest

    RE: I want brackets around my math equation answer?

    tried the formula you have below but couldn't get it to work.

    "Martin P" wrote:

    > If you have feet in A1, to convert to metres in A2:
    > ="("&CONVERT(A1,"ft","m")&")"
    >
    > "Ms Serene" wrote:
    >
    > > I am putting together a equipment table that has to have entries in metric. I
    > > would like to set it up so that you type in the english units and it would
    > > the convert into metric on the next line. However i have to have Brackets
    > > around the Metric numbers...is there a way to do this?


  6. #6
    Greg Wilson
    Guest

    RE: I want brackets around my math equation answer?

    Martin's formula works fine for me assuming you want to convert imperial to
    metric and also put parentheses around it. You must however have the Analysis
    Toolpack add-In selected: Tools > Add-Ins > Analysis Toolpack checkbox

    Regards,
    Greg

    "Ms Serene" wrote:

    > tried the formula you have below but couldn't get it to work.
    >
    > "Martin P" wrote:
    >
    > > If you have feet in A1, to convert to metres in A2:
    > > ="("&CONVERT(A1,"ft","m")&")"
    > >
    > > "Ms Serene" wrote:
    > >
    > > > I am putting together a equipment table that has to have entries in metric. I
    > > > would like to set it up so that you type in the english units and it would
    > > > the convert into metric on the next line. However i have to have Brackets
    > > > around the Metric numbers...is there a way to do this?


  7. #7
    David Biddulph
    Guest

    Re: I want brackets around my math equation answer?

    Would you like to give us a clue by telling us what result you got?

    Did you look up the CONVERT function in Excel help?

    Did that give you an answer?

    David Biddulph

    "Ms Serene" <MsSerene@discussions.microsoft.com> wrote in message
    news:989D80A4-1305-41DF-BC5A-7D5EB301CC05@microsoft.com...
    > tried the formula you have below but couldn't get it to work.


    > "Martin P" wrote:
    >
    >> If you have feet in A1, to convert to metres in A2:
    >> ="("&CONVERT(A1,"ft","m")&")"


    >> "Ms Serene" wrote:
    >>
    >> > I am putting together a equipment table that has to have entries in
    >> > metric. I
    >> > would like to set it up so that you type in the english units and it
    >> > would
    >> > the convert into metric on the next line. However i have to have
    >> > Brackets
    >> > around the Metric numbers...is there a way to do this?




+ 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