Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete cells
i have a worksheet with several columns, and i want to use one
specific colume as my reference, i.e. values under 100 in this column as well as values/texts in the same rows should be deleted, basically it's to delete a range of data based on certail value, is there a way? thanks a ton! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete cells
Assume the data is in column A.
Sub dltunder100() Dim c As Range lastRow = Cells(Rows.Count, 1).End(xlUp).Row For Each c In Range("A1:A" & lastRow) If c.Value < 100 Then c.EntireRow.Delete 'can be changed to a specific range End If Next End Sub " wrote: i have a worksheet with several columns, and i want to use one specific colume as my reference, i.e. values under 100 in this column as well as values/texts in the same rows should be deleted, basically it's to delete a range of data based on certail value, is there a way? thanks a ton! |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
delete cells
One posting will usually do it. See your first one.
" wrote: i have a worksheet with several columns, and i want to use one specific colume as my reference, i.e. values under 100 in this column as well as values/texts in the same rows should be deleted, basically it's to delete a range of data based on certail value, is there a way? thanks a ton! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
delete cells column. Delete empty cells | Excel Worksheet Functions | |||
how can I delete cells containing text within a range of cells | Excel Discussion (Misc queries) | |||
How to delete all the blanc cells in a worksheet and shift cells l | Excel Discussion (Misc queries) | |||
macro to select cells containing specific text and delete all cells but these | Excel Programming | |||
Delete specific cells contents in a row with some locked cells in the same row | Excel Programming |