Sunday, 22 December 2019
How to Deleting rows containing bold text in Excel
1. First open VBS (Alt + F11)
2. Then Select Sheet and Paste Below Code
Sub
del_rows_with_bold()
' David McRitchie, 2005-09-01
Application.ScreenUpdating = False
Application.Calculation =
xlCalculationManual
Dim Rcnt As Long, Ccnt As Long, r As
Long, c As Long
Dim CurrCell As Range
On Error Resume Next
Rcnt = Cells.SpecialCells(xlLastCell).Row
Ccnt =
Cells.SpecialCells(xlLastCell).Column
'-- check up to row 2 from the bottom
For r = Rcnt To 2 Step -1
'-- check all cells on row beginning
at column 1
For c = 1 To Ccnt
If Cells(r, c).Font.Bold And Not
IsEmpty(Cells(r, c)) Then
'-- Must be bold and have content
Cells(r, c).EntireRow.Delete
GoTo next_r
End If
Next c
next_r:
Next r
Application.Calculation = xlCalculationAutomatic
Application.ScreenUpdating = True
End Sub
|
How to Enable Dragging option in Excel
Display or
hide the fill handle
By default, the fill handle and drag-and-drop editing is
turned on in Excel so that you can drag the mouse to move and copy cells by
doing the following:
- Move
a cell or range of cells by positioning the mouse pointer on a cell or
cell range border so that it changes to a move pointer and
then dragging the cell to another location.
- Copy
a cell or range of cells by holding down CTRL while you position the mouse
pointer on a cell or cell range border so that it changes to a copy
pointer and
then dragging the cell or range of cells to another location.
- Drag
the fill handle to copy data
or to fill adjacent cells with a series of data.
You can turn this option on or off as needed by doing the
following:
- Click
File > Options.
- In
the Advanced category, under Editing options, select or
clear the Enable fill handle and cell drag-and-drop check box.
Note: To help prevent replacing existing data when you drag
the fill handle, make sure that the Alert before overwriting cells check
box is selected. If you do not want Excel to display a message about
overwriting non-blank cells, you can clear this check box.
Subscribe to:
Posts (Atom)