How to link checkboxes to multiple cells in Excel?
Link the checkboxes to multiple relative cells may help you to quickly and easily do some calculations when you need to sum, count or average only the checked or unchecked cells. But, have you ever tried to link the checkboxes to multiple cells at once in a worksheet?
Link checkboxes to multiple cells with formula one by one
Link checkboxes to multiple cells at once with VBA code
Link checkboxes to multiple cells with formula one by one
To link the checkbox to a specific cell, in fact, you can apply a simple formula to link them manually.
1. After inserting the checkboxes in your worksheet, to select the checkbox, please press Ctrl key and then click the first checkbox that you want to link to other cell.
2. Then in the formula bar, type the equal sign =, and then click one cell that you want to link the checkbox to, B2 for example, see screenshot:
3. And then press Enter key on the keyboard, now, when you check this checkbox, the linked cell will display TRUE, if uncheck it, it will display FALSE, see screenshot:
4. Repeated the above steps to link other checkboxes one by one.
Link checkboxes to multiple cells at once with VBA code
If there are hundreds and thousands checkboxes need to be linked to other cells, the first method will not work effectively, to link them to multiple cells at once, you can apply the following VBA code. Please do as this:
1. Go to your worksheet with the list of checkboxes.
2. Hold down the ALT + F11 keys to open the Microsoft Visual Basic for Applications window.
3. Click Insert > Module, and paste the following code in the Module Window.
VBA code: link checkboxes to multiple cells at once
Sub LinkChecks()
'Update by Extendoffice
Dim xCB
Dim xCChar
i = 2
xCChar = "B"
For Each xCB In ActiveSheet.CheckBoxes
If xCB.Value = 1 Then
Cells(i, xCChar).Value = True
Else
Cells(i, xCChar).Value = False
End If
xCB.LinkedCell = Cells(i, xCChar).Address
i = i + 1
Next xCB
End Sub
4. And then press F5 key to run this code, all checkboxes in the active worksheet have been linked to the cells, when you check the checkbox, its relative cell will display TRUE, if you clear a check box, the linked cell should show FALSE, see screenshot:
Note: In the above code, i = 2, the number 2 is the starting row of your checkbox, and the letter B is the column location where you need link the checkboxes to. You can change them to your need.
Related articles:
How to select all checkboxes using a single checkbox in Excel?
How to quickly insert multiple checkboxes in Excel?
How to quickly delete multiple checkboxes in Excel?
The Best Office Productivity Tools
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-2021 and 365. Supports all languages. Easy deploying in your enterprise or organization. Full features 30-day free trial. 60-day money back guarantee.

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!

















