#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 184
Default TRIM

Cell E1 has the name John followed by 13 spaces (comes out of the database
this way). How do I remove the 13 spaces? I tried trim((e1)&" "&g1) but it
doesn't work. Please help as this is driving me crazy. Thanks to those of you
who made suggestions already. I also tried the code in a simple Macro that is
application.trim(range("e1")) and can't seem to get that to work either.

Thanks
Nikki
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 515
Default TRIM

With your name in E1, insert a new column F.
Enter in F1 =TRIM(E1).
Select F1, copy, and paste special as value in E1. Your spaces should be
gone. Delete Col F

--
HTH

Kassie

Replace xxx with hotmail


"Nikki" wrote:

Cell E1 has the name John followed by 13 spaces (comes out of the database
this way). How do I remove the 13 spaces? I tried trim((e1)&" "&g1) but it
doesn't work. Please help as this is driving me crazy. Thanks to those of you
who made suggestions already. I also tried the code in a simple Macro that is
application.trim(range("e1")) and can't seem to get that to work either.

Thanks
Nikki

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,059
Default TRIM

"Nikki" wrote:
Cell E1 has the name John followed by 13 spaces [....].
How do I remove the 13 spaces? I tried trim((e1)&" "&g1)
but it doesn't work.


If you enter the formula __exactly__ the way Don told you to yesterday, you
should have no problem. Copy-and-paste the following formula:

=trim(e1)&" "&g1


----- original message -----

"Nikki" wrote in message
...
Cell E1 has the name John followed by 13 spaces (comes out of the database
this way). How do I remove the 13 spaces? I tried trim((e1)&" "&g1) but it
doesn't work. Please help as this is driving me crazy. Thanks to those of
you
who made suggestions already. I also tried the code in a simple Macro that
is
application.trim(range("e1")) and can't seem to get that to work either.

Thanks
Nikki


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default TRIM


See my reply at your other thread.

Please stay with one thread.


Gord Dibben MS Excel MVP

On Wed, 22 Apr 2009 08:29:03 -0700, Nikki
wrote:

Cell E1 has the name John followed by 13 spaces (comes out of the database
this way). How do I remove the 13 spaces? I tried trim((e1)&" "&g1) but it
doesn't work. Please help as this is driving me crazy. Thanks to those of you
who made suggestions already. I also tried the code in a simple Macro that is
application.trim(range("e1")) and can't seem to get that to work either.

Thanks
Nikki


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
=TRIM Shayra Excel Discussion (Misc queries) 5 October 16th 08 07:16 PM
Trim if? John Excel Worksheet Functions 6 June 26th 06 04:44 PM
Trim and Mid with VBA Jeff Excel Discussion (Misc queries) 1 April 19th 06 05:24 PM
Trim stapleton2308 Excel Discussion (Misc queries) 4 February 15th 06 06:09 PM
Trim help please Dave New Users to Excel 8 September 1st 05 07:18 PM


All times are GMT +1. The time now is 08:26 AM.

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

About Us

"It's about Microsoft Excel"