Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 84
Default Clear Blank Cells

In B1 I have =if(A1="this","that","") and continuing down b:b

i then copy b:b and paste special (value) into c:c

I have a sumproduct equation that runs off c:c. the problem is that
apparently the blank cells ("") arent really blank. I get a #VALUE error.
How can I find all the blank (''") cells and clearcontents?

Thanks in advance
jeff


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Clear Blank Cells

What you want to find and clear is "*" , which is wildcard any string.
That would find cells with formulas that equate to zero or "" .

"choice" wrote:

In B1 I have =if(A1="this","that","") and continuing down b:b

i then copy b:b and paste special (value) into c:c

I have a sumproduct equation that runs off c:c. the problem is that
apparently the blank cells ("") arent really blank. I get a #VALUE error.
How can I find all the blank (''") cells and clearcontents?

Thanks in advance
jeff


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Clear Blank Cells

Saved from a previous post:

If you want to see what's left in that cell after you convert ="" to values,
try:
Tools|Options|Transition Tab|Toggle Transition Navigation keys on.

Then select one of those cells and look at the formula bar. You'll see an
apostrophe. (Don't forget to toggle the setting to off.)

When I want to clean up this detritus, I do this:

Select the range (ctrl-a a few times to select all the cells)
Edit|Replace
what: (leave blank)
with: $$$$$
replace all

Immediately followed by:
Edit|Replace
what: $$$$$
with: (leave blank)
replace all

choice wrote:

In B1 I have =if(A1="this","that","") and continuing down b:b

i then copy b:b and paste special (value) into c:c

I have a sumproduct equation that runs off c:c. the problem is that
apparently the blank cells ("") arent really blank. I get a #VALUE error.
How can I find all the blank (''") cells and clearcontents?

Thanks in advance
jeff


--

Dave Peterson
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Clear Blank Cells

Consider:

Sub clear_blank()
For Each r In ActiveSheet.UsedRange
If r.HasFormula And r.Value = "" Then
r.Clear
End If
Next
End Sub

--
Gary''s Student - gsnu200746


"choice" wrote:

In B1 I have =if(A1="this","that","") and continuing down b:b

i then copy b:b and paste special (value) into c:c

I have a sumproduct equation that runs off c:c. the problem is that
apparently the blank cells ("") arent really blank. I get a #VALUE error.
How can I find all the blank (''") cells and clearcontents?

Thanks in advance
jeff


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
How to write a macro that will clear validated cells to blank? JAbels001 Excel Worksheet Functions 3 November 20th 08 05:20 PM
Clear Blank cells choice[_2_] Excel Programming 0 September 23rd 07 12:32 AM
How to clear 'blank' cells CaroleO Excel Discussion (Misc queries) 2 March 2nd 07 02:56 PM
clear range of cells if another becomes blank bgg Excel Worksheet Functions 3 January 17th 07 11:32 PM
Clear blank cells Reed[_3_] Excel Programming 4 January 22nd 05 01:00 AM


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