相关文章推荐
打酱油的小虾米  ·  Kafka configure jaas ...·  2 年前    · 
博学的双杠  ·  TextBoxBase.AutoSize ...·  2 年前    · 
1:在第一个单元格插入复选框后拖动复制。
2:如果单元格区域不规则可以用下面代码:
Private Sub AddCheckBoxesInRange()
On Error Resume Next
Dim cell As Range
Dim CurrentRange As Range

Set CurrentRange = Selection
CurrentRange.NumberFormatLocal = ";;;"
Application.ScreenUpdating = False
For Each cell In CurrentRange
ActiveSheet.CheckBoxes.Add(cell.Left, cell.Top, cell.Height, cell.Height).Select
With Selection
.Value = xlOff
.LinkedCell = cell.Address
.Display3DShading = False
.Characters.Text = ""
End With
Next
CurrentRange.Select
Application.ScreenUpdating = True

Set cell = Nothing

End Sub