View Single Post
  #3   Report Post  
PeterAtherton
 
Posts: n/a
Default cntrl + down arrow and null values in cells



"Dave Peterson" wrote:

If you have a formula that evaluates to "" (like =if(a10,"error","")) and it's
converted to values then this cell isn't really empty!

You can see this by (temporarily) toggling this setting:

Tools|options|transition tab|check Transition navigation keys.
You'll see an apostrophe in the formula bar.
(toggle that setting back!)



One way of cleaning up this detritus:

Select the range to fix
edit|replace
what: (leave blank)
with: $$$$$ (my unique string)
replace all

then one more time
edit|replace
what: $$$$$
with: (leave blank)
replace all



Dave Peterson


Assuming that there are no formulas you might have non printing characters.
If Daves method is too involved you could try this macro.

Sub clearNonBlanks()
Dim c
For Each c In Selection
'get rid of blanks
c.Value = Trim(c)
If IsDate(c) Then
c = c
End If
'ensure date values are correct
If IsNumeric(c) And _
Not IsDate(c) Then
c = c * 1
End If
If Asc(c) < 32 Then
c.Delete
End If
Next
End Sub

Copy sub into a VB Module, (ALT + F8, INsert Module) Select the all the
cells in the sheet and run the macro

Regards
Peter