Prev Previous Post   Next Post Next
  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 273
Default Removing Spaces

Hi Jim,

This looks like an interesting approach to my problem as I will need to do
this fairly regularly.

However, I have never used macros before and don not know where to place
your script? Or, indeed to use a macro!?

I've had a quick look and can't see where it should go?

Presumably I can save this 'macro' so I can just run it at a later date?

Many thanks
Gary

"Jim May" wrote:

Here's another approach (VBA has a function LTrim (Left Trim))
Before running Macro Highlight All your songs, say they are listed
in the range B5:B105 - and then Run Macro. Songs without a
starting space character will not be effected.

Sub ElimSpace()
For Each c In Selection
Fixedname = LTrim(c.Value)
c.Value = Fixedname
Next c
End Sub


"Gary" wrote:

Hello,

I have an Excel Spreadsheet that has a column that lists 100s of song titles
but the first charactor in each cell in this column is a space.

Is there a way of removing these spaces automatically?

Many thanks
Gary


 
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
removing all spaces jamesea Excel Discussion (Misc queries) 4 May 27th 07 02:18 PM
Removing spaces at the end of numbers Chris T. Excel Worksheet Functions 5 May 5th 07 06:22 AM
Removing spaces from columns Joni Hook Excel Worksheet Functions 2 May 26th 06 09:59 PM
removing spaces Claus Massmann Excel Discussion (Misc queries) 12 March 30th 06 02:23 AM
Removing Spaces in a Cell carl Excel Worksheet Functions 2 October 28th 04 11:34 PM


All times are GMT +1. The time now is 04:20 AM.

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

About Us

"It's about Microsoft Excel"