+ Reply to Thread
Results 1 to 4 of 4

help me to find a way to remove space without user intervention.

  1. #1
    Forum Contributor
    Join Date
    01-20-2011
    Location
    liverpool
    MS-Off Ver
    Excel 2016
    Posts
    198

    help me to find a way to remove space without user intervention.

    Hello,
    I have an xls where user is populating single digit number or leter.

    In some cases it apears that after the letter there is a space. Very often that is suggestion by excel which user is accepting and even does not realise that there is a space.
    Leter on there is another file that is reading that data and is counting number of specific letter and when there is a spece behind it is not counted.

    How this can be solved? I do not want to complicate reading formula by adding another condition (to count the letter with a space behind).
    I do not also want to use some condition during data entry and to complicate the life of the user by appearing some warning msg.
    Is there a way by VBA code or sth else those spaces to be trimmed on the background?

    Thanks a lot!!!
    Last edited by erkamu; 11-28-2018 at 11:32 AM.

  2. #2
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,028

    Re: help me to find a way to remove space without user intervention.

    Try this:
    Let's say the range in question is A1:A10, you might want to change it.
    Put this code in the sheet code window.

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    01-20-2011
    Location
    liverpool
    MS-Off Ver
    Excel 2016
    Posts
    198

    Re: help me to find a way to remove space without user intervention.

    Thanks a lot my friend. Worked very well.

  4. #4
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,028

    Re: help me to find a way to remove space without user intervention.

    Quote Originally Posted by erkamu View Post
    Thanks a lot my friend. Worked very well.
    You're welcome.
    Note: Is it possible for users to enter data (in the range in question) by copying-pasting data to more than one cell at once?
    If yes then we need to modify the code, because the code will not work if that happens.

+ 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. Remove from over 2 blank space to 1 space.
    By calvinle in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 02-12-2018, 08:27 PM
  2. Replies: 7
    Last Post: 05-23-2016, 07:27 PM
  3. [SOLVED] To remove Space
    By Shradharani in forum Excel General
    Replies: 6
    Last Post: 02-17-2014, 09:41 AM
  4. [SOLVED] How to remove empty space, unable to make pvot, because pvot calculate empty space
    By vengatvj in forum Excel Charting & Pivots
    Replies: 20
    Last Post: 10-29-2013, 12:43 PM
  5. [SOLVED] If Cell Starts with a Space, remove that space
    By Ocean Zhang in forum Excel General
    Replies: 2
    Last Post: 09-29-2012, 01:52 PM
  6. Answer Excel 'yes/no' question in Macro without user intervention?
    By dingman4 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-10-2007, 01:35 PM
  7. User Intervention Required When Opening Workbooks
    By Rob Fernando in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-14-2005, 10:05 AM

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