Can a checkbox be placed 'within a row'?

  • Thread starter Thread starter Dan R.
  • Start date Start date
D

Dan R.

What I'm trying to do is place checkboxes in the first column of my
spreadsheet so that the user can check the box if they want to process
the data in that particular row. Probably not possible huh? Any
suggestions?

Thanks,
-- Dan
 
Does the sheet need to be sortable ? If not then you can use option buttons
from the forms toolbar

You could try something like this:

'***********************
Option Explicit

Sub Tester()

Const R_START As Integer = 3
Dim i As Integer
Dim c As Range, s As String

For i = 1 To 10
Set c = ActiveSheet.Cells(R_START + i - 1, 1)
s = "chkBox_" & Right("000" & i, 3)

On Error Resume Next
ActiveSheet.CheckBoxes(s).Delete
On Error GoTo 0

With ActiveSheet.CheckBoxes.Add(c.Left, c.Top - 1, 15, 15)
.Characters.Text = ""
.Name = s
End With
Next i

End Sub
'************************
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top