#1   Report Post  
Posted to microsoft.public.excel.programming
C3 C3 is offline
external usenet poster
 
Posts: 13
Default Macro

Help!

How to make a macro who will find every cell (in a specific column - for
example, column B) and erase content, if that content is a number with one,
two, three, four or five digits.

For example:

Cell 1 3858884116322
Cell 2 3856003215644
Cell 3 41862
Cell 4 4569888
Cell 5 499
Cell 6 0


Macro must eliminate (just erase content - not cell) cell 3, 5 and 6 (column
B).

Thanx.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 93
Default Macro

C3,
If you are dealing with numbers only
select your range and run this macro

Sub Macro1()
For Each cell In Selection
If cell.Value < 100000 Then
cell.ClearContents
End If
Next
End Sub

HTH
Cecil

"C3" wrote in message
...
Help!

How to make a macro who will find every cell (in a specific column - for
example, column B) and erase content, if that content is a number with

one,
two, three, four or five digits.

For example:

Cell 1 3858884116322
Cell 2 3856003215644
Cell 3 41862
Cell 4 4569888
Cell 5 499
Cell 6 0


Macro must eliminate (just erase content - not cell) cell 3, 5 and 6

(column
B).

Thanx.




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
Macro recorded... tabs & file names changed, macro hangs Steve Excel Worksheet Functions 3 October 30th 09 11:41 AM
need help to update macro to office 2007 macro enabled workbook jatman Excel Discussion (Misc queries) 1 December 14th 07 01:57 PM
Macro Help Needed - Excel 2007 - Print Macro with Auto Sort Gavin Excel Worksheet Functions 0 May 17th 07 01:20 PM
Macro needed to Paste Values and prevent Macro operation thunderfoot Excel Discussion (Misc queries) 0 June 10th 05 03:38 PM
Start Macro / Stop Macro / Restart Macro Pete[_13_] Excel Programming 2 November 21st 03 05:04 PM


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