Tip: Other languages are Google-Translated. You can visit the English version of this link.
Log in
x
or
x
x
Register
x

or

How to filter cells by bold characters in Excel?

You can apply the bold font style to format the data or contents in cells in Excel, but do you know how to filter cells by the cells which containing bold font style in Excel? This article collects several tricky VBA macros to filter cells by bold characters in Excel.

Filter bold cells with the helper column
Filter bold cells with the VBA code
Easily filter bold cells with an amazing tool
More tutorials for data filtering…


Quickly filter bold cells in a column with several clicks in Excel:

The Filter Bold cells utility of Kutools for Excel can help you quickly filter all bold cells in a certain column with several clicks as the below demo shown.
Download the full feature 30-day free trail of Kutools for Excel now!


Filter bold cells with the help column

Supposing you need to filter all bold cells in column B as below screenshot shown, please do as follows:

The below user-defined function helps to identify whether a cell in a column is bold or not, and then return the results as TRUE or False in a helper column. You can filter all TRUE results to display only the bold cells in column B.

1. Press the Alt + F11 keys to open the Microsoft Visual Basic for Application window.

2. In the Microsoft Visual Basic for Application window, click Insert > Module, then copy the following VBA code into the Module window. See screenshot:

VBA code: Filter cells by bold characters

Function IsBold(rCell As Range)
IsBold = rCell.Font.Bold
End Function

3. Press the Alt + Q keys to close the code window.

4. Select a blank cell which is adjacent to the table (the selected cell should locate on the same row of the first row in the filter table), copy the below formula into it and press the enter key.

=IsBold(B2)

5. Keep selecting the first result cell, and drag the Fill Handle to get all results. See screenshot:

6. Select the header of the helper column, click Data > Filter. Click the arrow button besides the header cell, check the TRUE box only, and then click OK.

Now all bold cells in column B are filtered out as below screenshot shown.


Filter bold cells with the VBA code

The below VBA code allows you to filter all bold cells in one column directly. Please do as follows.

Before applying Kutools for Excel, please download and install it firstly.

1. Select the column range you will filter out all bold cells except the header cell. In this case, I select B2:B16.

2. Press the Alt + F11 keys to open the Microsoft Visual Basic for Application window.

3. In the Microsoft Visual Basic for Application window, click Insert > Module, then copy and paste the following VBA code into the Module window.

VBA code: Filter bold cells in a column

Sub FilterBold()
'Updated by Extendoffice 20191018
Dim cell As Range
For Each cell In Selection
If cell.Font.Bold = False Then
cell.EntireRow.Hidden = True
End If
Next cell
End Sub

4. Press the F5 key to run this macro. Then all bold cells are filtered out in selected column range immediately.


Easily filter bold cells with an amazing tool

In this section, we are recommend you a handy tool – the Filter Bold cells utility of Kutools for Excel. With this utility, all bold cells in selected column are filtered immediately with several clicks.

1. Select the column range you will filter the bold cells, click Kutools Plus> Special Filter > Filter Bold to get it done. See below demo:

  If you want to have a free trial ( 30-day) of this utility, please click to download it, and then go to apply the operation according above steps.


Related articles

Filter multiple columns simultaneously in Excel
After filtering one column with the Filter feature, only AND criteria can be applied to more than one column. In this case, how could you apply both the AND and OR criteria to filter multiple columns simultaneously in Excel worksheet? Methods in this article can do you a favor.

Filter or select cells by cell color in Excel
Normally you can fill cells with different colors for any purposes in Excel. If you have a worksheet with using different colors to indicate different type of contents and you want to filter or select those cells by the cell color, you may get it done with the methods in this article.

Paste skipping hidden/filtered cells and rows in Excel
For example, you have filtered a table in Excel, but now you need to copy a range and paste into this filtered table, do you know how to paste skipping the hidden/filtered cells and rows? Several easy ways in this article can help you.

Filter rows based on a list selection in another sheet
In Excel, we usually filter rows based on a criteria, but if there are two list, one is in Sheet1, and another in Sheet2, could you have any tricks to quickly filter rows in Sheet1 based on the list in Sheet2? Here this article introduces the ways on solving this job.

Filter all related data from merged cells in Excel
Supposing there is a column of merged cells in your data range, and now, you need to filter this column with merged cells to show all the rows which are related with each merged cell as following screenshots shown. In excel, the Filter feature allows you to filter only the first item which associated with the merged cells, in this article, we are talking about how to filter all related data from merged cells in Excel.

More tutorials for data filtering…


Kutools for Excel Solves Most of Your Problems, and Increases Your Productivity by 80%

  • Reuse: Quickly insert complex formulas, charts and anything that you have used before; Encrypt Cells with password; Create Mailing List and send emails...
  • Super Formula Bar (easily edit multiple lines of text and formula); Reading Layout (easily read and edit large numbers of cells); Paste to Filtered Range...
  • Merge Cells/Rows/Columns without losing Data; Split Cells Content; Combine Duplicate Rows/Columns... Prevent Duplicate Cells; Compare Ranges...
  • Select Duplicate or Unique Rows; Select Blank Rows (all cells are empty); Super Find and Fuzzy Find in Many Workbooks; Random Select...
  • Exact Copy Multiple Cells without changing formula reference; Auto Create References to Multiple Sheets; Insert Bullets, Check Boxes and more...
  • Extract Text, Add Text, Remove by Position, Remove Space; Create and Print Paging Subtotals; Convert Between Cells Content and Comments...
  • Super Filter (save and apply filter schemes to other sheets); Advanced Sort by month/week/day, frequency and more; Special Filter by bold, italic...
  • Combine Workbooks and WorkSheets; Merge Tables based on key columns; Split Data into Multiple Sheets; Batch Convert xls, xlsx and PDF...
  • More than 300 powerful features. Supports Office/Excel 2007-2019 and 365. Supports all languages. Easy deploying in your enterprise or organization. Full features 30-day free trial.
kte tab 201905

Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!
officetab bottom
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.
  • To post as a guest, your comment is unpublished.
    richard skins · 3 years ago
    I've used this technique and had an issue when trying to copy the bold data. It only copies some of the data for some reason.

    Is there any way of copying only the bold data using this technique?

    Thanks,

    Richard
    • To post as a guest, your comment is unpublished.
      crystal · 2 years ago
      Dear richard skins,



      We didn't encounter the problem as you mentioned. Would you please provide a screenshot with details of your operation?



      Thank you for your comment!
  • To post as a guest, your comment is unpublished.
    richard skins · 3 years ago
    Hi,

    I'm a complete excel novice, i've done the following technique but now need to copy the data which is bold/true.

    When I have tried to do this is won't copy what is highlighted.

    Any ideas on how I can copy the data?

    Thanks,

    Richard
    • To post as a guest, your comment is unpublished.
      MUHAMMAD FAIZAN · 3 years ago
      @RICHARD

      Can u please provide any screenshot of your spreadsheet showing what u are exactly trying to do?
  • To post as a guest, your comment is unpublished.
    Star Lay · 3 years ago
    Thanks for sharing. It works wonderful.
  • To post as a guest, your comment is unpublished.
    Nitin Jain · 3 years ago
    Hi I am using this code and its working fine but whenever I click on cancel the dialogue box a popup window appear and shows some error. Can you please tell me how to remove that error.




    :Sub FilterBold()
    Dim myRange As Range
    Set myRange = Application.InputBox(Prompt:="Please Select a Range", Title:="InputBox Method", Type:=8)
    myRange.Select
    Application.ScreenUpdating = False
    For Each myRange In Selection
    If myRange.Font.Bold = False Then
    myRange.EntireRow.Hidden = True
    End If
    Next myRange
    Application.ScreenUpdating = True
    End Sub
    • To post as a guest, your comment is unpublished.
      crystal · 2 years ago
      Dear Nitin Jain,

      Sorry to reply so late!

      We have found the proble and fixed it already. The VBA script in the article is now updated,

      Thank you for your comment!
  • To post as a guest, your comment is unpublished.
    Nicholas · 4 years ago
    Simple and brilliant, thank you!
  • To post as a guest, your comment is unpublished.
    Statistics Guru · 5 years ago
    This worked perfectly, thank you!!! :D :lol:
  • To post as a guest, your comment is unpublished.
    cadafi · 6 years ago
    I presume that column A is the reference Column with Bold cells.
    I create a Name "Bold?" with the refer to as below

    =GET.CELL(20,OFFSET(INDIRECT("A1"),ROW()-1,0))

    In column B, I type:
    =Bold?

    Copy down the formula and then use autofilter to filter the value TRUE. DONE
    • To post as a guest, your comment is unpublished.
      Mohammad Faizan · 5 years ago
      @cadafi
      ur formula works fine but it is not the optimised or efficient use of it.
      Rather we should use direct reference of the range or a cell in place of that complete offset command.
      Like the one as follows:

      =GET.CELL(20,'Sheet1'!A1)

      Copy down the formula and then use autofilter to filter the value TRUE. DONE
      • To post as a guest, your comment is unpublished.
        cadafi · 5 years ago
        Thanks Mohamand Faizan. You are entirely correct.
      • To post as a guest, your comment is unpublished.
        cadafi · 5 years ago
        @Mohammad Faizan
        You are entirely correct. Thanks.
    • To post as a guest, your comment is unpublished.
      Anjali · 5 years ago
      @Cadafi.... thats brilliant... wondering how it works though!