+ Reply to Thread
Results 1 to 11 of 11

How do I get excel to simply display values without doing math?

  1. #1
    Registered User
    Join Date
    07-21-2019
    Location
    oregon
    MS-Off Ver
    2016 Home and student
    Posts
    6

    Question How do I get excel to simply display values without doing math?

    To be more specific, I have columns with data that I'm trying to get excel to automatically combine into a code. For example

    101-102.001-002-L3

    In which the above is (value1)(value2)-(Value3).(value4)-(Value5)-(Value6)(value7)

    This way all I need to do is input the data into the columns and Excel can spit out the code for me, fully formed. But I just don't know enough to make it do that, I'm sure its possible however. I'm just trying to keep from having to log the values and type out the string as well.

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,879

    Re: How do I get excel to simply display values without doing math?

    Look at the Concatenate Function

    https://www.techonthenet.com/oracle/...ons/concat.php
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,780

    Re: How do I get excel to simply display values without doing math?

    Assuming the values are each in cells, maybe something like this:

    =A1&B1&"-"&C1&"."&D1&"-"&E1&"-"&F1&G1
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  4. #4
    Registered User
    Join Date
    07-21-2019
    Location
    oregon
    MS-Off Ver
    2016 Home and student
    Posts
    6

    Re: How do I get excel to simply display values without doing math?

    I will definitely look into this thank you.

  5. #5
    Registered User
    Join Date
    07-21-2019
    Location
    oregon
    MS-Off Ver
    2016 Home and student
    Posts
    6

    Re: How do I get excel to simply display values without doing math?

    Quote Originally Posted by AliGW View Post
    Assuming the values are each in cells, maybe something like this:

    =A1&B1&"-"&C1&"."&D1&"-"&E1&"-"&F1&G1
    This worked but I'm going to have to set my own formatting because it came back as 11-2.0-0-S5
    Still this is a big step in the right direction, thank you.

  6. #6
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,780

    Re: How do I get excel to simply display values without doing math?

    "It came back as ..."

    What came back as?

    You need to be more specific. Provide some before and after data, otherwise we are working in the dark. I gave a solution based on what you told us.

    You can use things like this:

    =TEXT(A1,"000")

    to force formatting within the string.

    The missing information is the starting values - what exactly will be in those cells?
    Last edited by AliGW; 07-22-2019 at 01:57 AM.

  7. #7
    Registered User
    Join Date
    07-21-2019
    Location
    oregon
    MS-Off Ver
    2016 Home and student
    Posts
    6

    Re: How do I get excel to simply display values without doing math?

    Apologies, what I meant was that excel did convert the data into a string but the data needs to appear as 000-000.000-000-00. I was having some trouble getting it to do that but I've worked it out I think, though excel is giving me copious "Are you sure this is supposed to be text and not a number?" errors. A friend and I were trying to solve the issue and he discovered if you convert the cells to be "text" then I finally get the format I want. I want it to display 101-002.000-000-S5, what excel was giving me was 11-2-0-0-S5. That was the formatting I was trying to correct. We found a solution but I'm curious if there is a better one since now excel recommends every cell be converted back to number which is okay, but ugly. But anyways let me leave off with this example here. I have had to manually ignore the errors for them to stay gone, though that's not a sustainable answer.

    Attachment 633699
    Last edited by AliGW; 07-23-2019 at 01:06 AM.

  8. #8
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,780

    Re: How do I get excel to simply display values without doing math?

    It sounds to me that you have gone about this the wrong way, but the attachment is invalid, wo I can't look at your spreadsheet to check. If you attach a sample workbook I can advise.

    Administrative Note:

    Please don't quote whole posts, especially when you are responding to the one immediately preceding your own - it's just clutter. It's OK to quote if you are responding to a post out of sequence, but limit quoted content to a few relevant lines that makes clear to whom and what you are responding. Thanks!

    For normal conversational replies, try using the QUICK REPLY box below.

  9. #9
    Registered User
    Join Date
    07-21-2019
    Location
    oregon
    MS-Off Ver
    2016 Home and student
    Posts
    6

    Re: How do I get excel to simply display values without doing math?

    Fair enough, I'm not one who hops on forums much. Please forgive my ignorance. I've attached a sample file. Thank you for your help and patience.
    Attached Files Attached Files

  10. #10
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,780

    Re: How do I get excel to simply display values without doing math?

    Here's the way I would have done it (by controlling the formatting via the formula rather than formatting the source cells):

    Excel 2016 (Windows) 32 bit
    A
    B
    C
    D
    E
    F
    G
    H
    4
    101-002.000-000-45
    1
    1
    2
    0
    0
    4
    5
    Sheet: Sheet1

    =B4&TEXT(C4,"00")&"-"&TEXT(D4,"000")&"."&TEXT(E4,"000")&"-"&TEXT(F4,"000")&"-"&G4&H4
    Attached Files Attached Files

  11. #11
    Registered User
    Join Date
    07-21-2019
    Location
    oregon
    MS-Off Ver
    2016 Home and student
    Posts
    6

    Re: How do I get excel to simply display values without doing math?

    Fantastic, thank you for all your help. This is going to make code generation and data entry much easier. Before I was having to log the data and manually generate the code. I appreciate all your help.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Paste Operation is Simply Dropping Certain Text Values
    By deekadelic in forum Access Tables & Databases
    Replies: 0
    Last Post: 07-18-2016, 12:40 PM
  2. Simply minus calculation, if the result is less than 0, then display 0
    By tiggi in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 03-26-2013, 02:18 PM
  3. Excel 2010's pivot tables insist on imposing basic math on my values.
    By cdoggown in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 01-29-2013, 01:36 AM
  4. Replies: 3
    Last Post: 02-16-2006, 07:00 AM
  5. How do I simply output Deciles in Excel?
    By iceman30 in forum Excel General
    Replies: 1
    Last Post: 09-26-2005, 02:05 PM
  6. Replies: 12
    Last Post: 07-13-2005, 07:05 PM
  7. VBA programming: Simply trying to select cell-- or not so simply?
    By whiteliyl_111 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-10-2005, 01:18 PM

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