+ Reply to Thread
Results 1 to 13 of 13

Number and Word in the same cell

  1. #1
    Bob Martin
    Guest

    Number and Word in the same cell

    I want to be able to have a number and a word in the same cell, but still be
    able to use formulas to add, subtract, ect. to the number.
    For example: I have 6 meters in cell A1 and want to add 11.9 meters

  2. #2
    JMB
    Guest

    RE: Number and Word in the same cell

    If

    A1 = 6 meters
    A2 = 11.9 meters

    =VALUE(LEFT(A1,SEARCH(" ",A1,1)-1))+VALUE(LEFT(A2,SEARCH(" ",A2,1)-1))

    "Bob Martin" wrote:

    > I want to be able to have a number and a word in the same cell, but still be
    > able to use formulas to add, subtract, ect. to the number.
    > For example: I have 6 meters in cell A1 and want to add 11.9 meters


  3. #3
    Gary''s Student
    Guest

    RE: Number and Word in the same cell

    An alternative method is to format Cell > Number > Custom to something like

    General" meters" The value can be used directly.
    --
    Gary''s Student


    "JMB" wrote:

    > If
    >
    > A1 = 6 meters
    > A2 = 11.9 meters
    >
    > =VALUE(LEFT(A1,SEARCH(" ",A1,1)-1))+VALUE(LEFT(A2,SEARCH(" ",A2,1)-1))
    >
    > "Bob Martin" wrote:
    >
    > > I want to be able to have a number and a word in the same cell, but still be
    > > able to use formulas to add, subtract, ect. to the number.
    > > For example: I have 6 meters in cell A1 and want to add 11.9 meters


  4. #4
    BizMark
    Guest

    Re: Number and Word in the same cell


    There's an easier way than that. If you simply type into

    A1 = 6
    A2 = 11.9

    as pure numbers (i.e. omit the word "metres"), you can then select A1
    and A2, go to the 'Format' menu 'Cells...' and on the 'Number' tab,
    choose 'Custom' type number formatting.

    Then, for the format string (which will by default in this instance
    read 0 or 0.0 or General), type in 0.0 "metres" - i.e. zero point zero,
    followed by a space, followed by quote, followed by the word metres,
    followed by another quote.

    Your cells will then appear like this:
    A1 = 6.0 metres
    A2 = 11.9 metres

    BUT the underlying cell contents are purely the numeric values 6 and
    11.9, and can therefore be calculated upon without having to trim the
    strings out. e.g. you could total them simply with =A1+A2. Simply
    apply the same formatting as described above to get the result to also
    append the phrase "metres".

    BizMark


    --
    BizMark

  5. #5
    JMB
    Guest

    RE: Number and Word in the same cell

    Never seen or tried that trick before. That's pretty cool.

    Thanks!

    "JMB" wrote:

    > If
    >
    > A1 = 6 meters
    > A2 = 11.9 meters
    >
    > =VALUE(LEFT(A1,SEARCH(" ",A1,1)-1))+VALUE(LEFT(A2,SEARCH(" ",A2,1)-1))
    >
    > "Bob Martin" wrote:
    >
    > > I want to be able to have a number and a word in the same cell, but still be
    > > able to use formulas to add, subtract, ect. to the number.
    > > For example: I have 6 meters in cell A1 and want to add 11.9 meters


  6. #6
    Forum Contributor
    Join Date
    05-27-2004
    Posts
    119
    Hi BizMark,
    I got a long troubling solution by your answer. Thank you very much. Now a related question, if you kindly solve this, it helps a lot to me.
    One of a cell having Amount which i convert now as 5000/= (like you suggest number "/="). But when small denomination comes, i wanted the same cell to be like normal earlier format that is like this 5000.50
    Is it possible by using "IF" formula or do you have any other alternative solution.
    Thanks and regards.
    NOWFAL

  7. #7
    Forum Contributor
    Join Date
    05-27-2004
    Posts
    119
    hi,
    Anybody can help?

  8. #8
    Ragdyer
    Guest

    Re: Number and Word in the same cell

    Don't know if I exactly understand what you're asking.

    Use this custom format to display values >= 1000 as:
    1000/=
    And values under 1000 as:
    999.00

    [<1000]0.00;0"/="
    --
    HTH,

    RD

    ---------------------------------------------------------------------------
    Please keep all correspondence within the NewsGroup, so all may benefit !
    ---------------------------------------------------------------------------
    "nowfal" <[email protected]> wrote in
    message news:[email protected]...
    >
    > hi,
    > Anybody can help?
    >
    >
    > --
    > nowfal
    > ------------------------------------------------------------------------
    > nowfal's Profile:

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



  9. #9
    Forum Contributor
    Join Date
    05-27-2004
    Posts
    119
    Hi Ragdyer,
    Thanks for the reply. What you mention is below 1000. My requirement is any amount which is having cents should show like 1000.50 and which is not having cents should be like 1000/=
    I hope you got my problem.
    thanks and regards
    NOWFAL

  10. #10
    RagDyer
    Guest

    Re: Number and Word in the same cell

    I don't think it can be done.

    BUT ... others may have some ideas.
    --
    Regards,

    RD

    ---------------------------------------------------------------------------
    Please keep all correspondence within the NewsGroup, so all may benefit !
    ---------------------------------------------------------------------------

    "nowfal" <[email protected]> wrote in
    message news:[email protected]...
    >
    > Hi Ragdyer,
    > Thanks for the reply. What you mention is below
    > 1000. My requirement is any amount which is having cents should show
    > like 1000.50 and which is not having cents should be like 1000/=
    > I hope you got my problem.
    > thanks and regards
    > NOWFAL
    >
    >
    > --
    > nowfal
    > ------------------------------------------------------------------------
    > nowfal's Profile:

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



  11. #11
    Forum Contributor
    Join Date
    05-27-2004
    Posts
    119
    Hi Ragdyer,
    Thanks for reply. I also thinking that way. Hope somebody will have some new tricks.
    nowfal

  12. #12
    Forum Contributor
    Join Date
    03-13-2005
    Posts
    6,195
    Perhaps

    =IF(MOD(A1,1)<>0,TEXT(A1,"0000.00")&" metres",TEXT(A1,"0000")&"/= metres")

    will suit your needs, but the question does seem to have drifted a little from metres to cents.



    Quote Originally Posted by nowfal
    Hi Ragdyer,
    Thanks for reply. I also thinking that way. Hope somebody will have some new tricks.
    nowfal
    Last edited by Bryan Hessey; 10-25-2005 at 08:44 AM.

  13. #13
    Forum Contributor
    Join Date
    05-27-2004
    Posts
    119
    Yes, exactly right formula. This is why this forum seems to be the best. thanks to
    Bryan Hessey, and all those help early.
    the corrected formula is as
    =IF(MOD(a1,1)<>0,TEXT(a1,"0.00")&" ",TEXT(a1,"0")&"/= ")
    thanks and regards
    nowfal

+ 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