Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 72
Default erasing space/blank in a cell

Hi
i'm doing alot of vlookup work and very common to facea problem in
linking becaouse of additional space or blank line
does anyone have an idea how can it be overcomed?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,276
Default erasing space/blank in a cell

Hi,
try this, highlight the column where you have the information, ctrl H, that
will take it to the replace screen, let's say you have 1 blank space, in find
what press the space bar one , then tab to replace with, don't do anything
here and press replace all. hope this help

"thread" wrote:

Hi
i'm doing alot of vlookup work and very common to facea problem in
linking becaouse of additional space or blank line
does anyone have an idea how can it be overcomed?

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default erasing space/blank in a cell

On 15 Jan., 15:17, thread wrote:
Hi
i'm doing alot of vlookup work and very common to facea problem in
linking becaouse of additional space or blank line
does anyone have an idea how can it be overcomed?


Hi,

there is a function called trim. This enables you to take out all the
spaces at the beginning of the cell. Maybe that one helps
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22,906
Default erasing space/blank in a cell

Sub TRIM_EXTRA_SPACES()
Dim Cell As Range
For Each Cell In Selection
If (Not IsEmpty(Cell)) And _
Not Application.IsNumber(Cell.Value) And _
InStr(Cell.Formula, "=") = 0 _
Then Cell.Value = Application.Trim(Cell.Value)
Next
End Sub


Gord Dibben MS Excel MVP

On Thu, 15 Jan 2009 06:17:08 -0800 (PST), thread wrote:

Hi
i'm doing alot of vlookup work and very common to facea problem in
linking becaouse of additional space or blank line
does anyone have an idea how can it be overcomed?


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
Delete content of cell without erasing existing formula? duethckey Excel Discussion (Misc queries) 1 October 22nd 07 06:58 PM
add blank space in cell if first name is not blank stef Excel Worksheet Functions 6 August 23rd 06 02:26 AM
Code Erasing Cell Contents Inappropriately Paige Excel Programming 2 March 7th 06 05:51 PM
I want a blank space on a worksheet when the question is blank? Patrizia Excel Discussion (Misc queries) 2 June 23rd 05 12:51 AM
How do I clear blank space at the top of a word-wrapped text cell? mirage1210 Excel Discussion (Misc queries) 2 February 11th 05 09:19 PM


All times are GMT +1. The time now is 08:35 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"