A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Need better understanding of TRIM so I can get rid of trailing spa



 
 
Thread Tools Display Modes
  #1  
Old August 9th, 2005, 10:05 PM
Tom Q
external usenet poster
 
Posts: n/a
Default Need better understanding of TRIM so I can get rid of trailing spa

I imported a listof names to creat labels. All columns have trailing spaces.
I have imported some into Word then done a relace it worked but it was a not
the right solution. I understand TRIM in Excel will get rid of Trailing
spaces. The examples HELP gives is not clear to me. Please help me get rid of
these trailing spaces.

Tom
  #2  
Old August 9th, 2005, 11:14 PM
Alan
external usenet poster
 
Posts: n/a
Default

If you want to delete all spaces the just use Edit Replace 'space'
Replace With 'nothing' Replace All

=TRIM(A1) will remove both leading and trailing spaces except a space
between two words. In a convenient column enter =TRIM(your cell) and drag it
down to the end of the list and then Paste Special Values to lose the
formulas.

However if this list you've imported comes from a web site the spaces may
not be ASCII32, CHAR(32) in XL, but could be ASCII160, CHAR(160) in Xl.
This looks like a normal space but isn't so the TRIM function wont find it.

Try highlighting the whole sheet, go Edit Replace Replace What hold
down the Alt key and type 0160 (nothing will appear in the dialogue box)
Replace with 'nothing' Replace All

Regards,
Alan.
"Tom Q" Tom wrote in message
...
I imported a listof names to creat labels. All columns have trailing
spaces.
I have imported some into Word then done a relace it worked but it was a
not
the right solution. I understand TRIM in Excel will get rid of Trailing
spaces. The examples HELP gives is not clear to me. Please help me get rid
of
these trailing spaces.

Tom



 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Need better understanding of TRIM so I can get rid of trailing spa Tom Q General Discussion 1 August 9th, 2005 10:24 PM
Access question about the Trim function kendy General Discussion 5 March 9th, 2005 03:33 AM
Trim function doesn't clean out ASCII Code 160 (Space) Ronald Dodge Worksheet Functions 6 January 27th, 2005 03:48 AM
Trim Statement James C. Running & Setting Up Queries 1 January 25th, 2005 10:44 PM
Trim in label reports Diana Setting Up & Running Reports 3 May 28th, 2004 01:04 AM


All times are GMT +1. The time now is 01:16 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.