+ Reply to Thread
Results 1 to 7 of 7

How to add white spaces to the end

  1. #1
    Registered User
    Join Date
    11-11-2014
    Location
    usa
    MS-Off Ver
    tn
    Posts
    23

    How to add white spaces to the end

    I have a formula in R2 that needs to equal 25 total characters with white spaces at the end.
    formula so far is. =K2&L2&" "&E2&"BL"&D2.
    How can I require the remaining?

  2. #2
    Valued Forum Contributor
    Join Date
    01-07-2013
    Location
    Michigan
    MS-Off Ver
    O365
    Posts
    601

    Re: How to add white spaces to the end

    Someone else may have a more compact way of doing this. Try:
    Please Login or Register  to view this content.
    Does that give you what you're looking for?
    If someone helped achieve your solution, consider clicking "* Add Reputation" on their post.

    If your question has been answered, mark the thread as [SOLVED] using the Thread Tools menu at the top of the thread.

  3. #3
    Registered User
    Join Date
    11-11-2014
    Location
    usa
    MS-Off Ver
    tn
    Posts
    23

    Re: How to add white spaces to the end

    Excellent
    That did the trick

    Thank you

  4. #4
    Valued Forum Contributor
    Join Date
    01-07-2013
    Location
    Michigan
    MS-Off Ver
    O365
    Posts
    601

    Re: How to add white spaces to the end

    You're welcome, happy to help.

  5. #5
    Forum Expert Roel Jongman's Avatar
    Join Date
    03-28-2015
    Location
    Netherlands
    MS-Off Ver
    Office 365
    Posts
    1,482

    Re: How to add white spaces to the end

    the shorter version would be

    Please Login or Register  to view this content.
    Last edited by Roel Jongman; 05-13-2019 at 04:51 PM.

  6. #6
    Registered User
    Join Date
    11-11-2014
    Location
    usa
    MS-Off Ver
    tn
    Posts
    23

    Re: How to add white spaces to the end

    One more question please how would i remove all white space in all columns but add the remaining to R2 to total 25?
    I think it is already doing it with the Len correct?

    =IF(LEN(K2&L2&" "&E2&"BL"&C2)<25,K2&L2&" "&E2&"BL"&C2 & REPT(" ",25-LEN(K2&L2&" "&E2&"BL"&C2)),K2&L2&" "&E2&"BL"&C2)
    Last edited by booney440; 05-13-2019 at 06:10 PM.

  7. #7
    Forum Expert
    Join Date
    10-15-2018
    Location
    MA, USA
    MS-Off Ver
    2010, 2019
    Posts
    1,616

    Re: How to add white spaces to the end

    Another version:
    =LEFT(K2&L2&" "&E2&"BL"&D2 & REPT(" ", 25), 25)

+ 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. [SOLVED] Eliminate white spaces longer than one space
    By plans in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-15-2018, 09:17 PM
  2. [SOLVED] RegEx to eliminat white spaces form a string
    By plans in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-06-2016, 04:48 PM
  3. [SOLVED] remove white spaces in a specific column
    By stoey in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-12-2014, 11:57 PM
  4. [SOLVED] How to remove white spaces from a phrase?
    By sami770 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-30-2014, 02:02 PM
  5. Remove White Spaces from all cells
    By modest_16081982 in forum Excel General
    Replies: 18
    Last Post: 05-03-2013, 07:22 AM
  6. Copy cell value and delete white spaces?
    By gombi in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 10-04-2010, 08:24 AM
  7. Remove white spaces in Back
    By dziw in forum Excel General
    Replies: 2
    Last Post: 07-19-2006, 01:55 PM

Tags for this Thread

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