Sub test()
Dim ToRow As Long
Dim LastRow As Long
Dim MyLeft As Double
Dim MyTop As Double
Dim MyHeight As Double
Dim MyWidth As Double
'--------------------------
LastRow = Range("D65536").End(xlUp).Row
For ToRow = 2 To LastRow
If Not IsEmpty(Cells(ToRow, "D")) Then
'-
MyLeft = Cells(ToRow, "C").Left
MyTop = Cells(ToRow, "C").Top
MyHeight = Cells(ToRow, "C").Height
MyWidth = MyHeight = Cells(ToRow, "C").Width
'-
ActiveSheet.CheckBoxes.Add(MyLeft, MyTop, MyWidth, MyHeight).Select
With Selection
.Caption = ""
.Value = xlOff
.LinkedCell = "C" & ToRow
.Display3DShading = False
'------------------------------------------------------
'- format
.Placement = xlFreeFloating
.PrintObject = True
'-------------------------------------------------------
.ShapeRange.Fill.Visible = msoTrue
.ShapeRange.Fill.Solid
.ShapeRange.Fill.ForeColor.SchemeColor = 13
.ShapeRange.Fill.Transparency = 0#
.ShapeRange.Line.Weight = 0#
.ShapeRange.Line.DashStyle = msoLineSolid
.ShapeRange.Line.Style = msoLineSingle
.ShapeRange.Line.Transparency = 0#
.ShapeRange.Line.Visible = msoTrue
.ShapeRange.Line.ForeColor.SchemeColor = 64
.ShapeRange.Line.BackColor.RGB = RGB(255, 255, 255)
'-------------------------------------------------------------
End With
End If
Next
End Sub