Check Boxes in Listview

R

Richard Krupa

Hi all,

When i put the checkboxes in list views how do i check the status of the
check box (True or False) for each row?

Appreciate the help!

Regards,
Richard
 
T

tina

if you're talking about a form in datasheet view, only one record at a time
is the current record. if you refer to the control name of the checkbox in
VBA, Access will look at the checkbox of the current record.

hth
 
R

Richard Krupa

Hi Tina,

I meant the ListView ActiveX control. You can set it so a check box appears
next to each row that allows you to tick it or not, im wondering how do i
test for that.

Regards,
Richard
 
T

tina

i don't know either, Richard. maybe somebody else will post and we'll both
learn something. :)
fyi, some busy people don't look at "already answered" posts, so hopefully
my addition to the subject line will catch their eye.
 
R

Richard Krupa

Hi Tina,

I worked it out.

Private Sub Command30_Click()
Dim cnt As Integer
For cnt = 1 To ListView1.ListItems.count
If ListView1.ListItems(cnt).Checked = True Then
MsgBox 1
End If
Next cnt
End Sub

Thanks for the help :)
 

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

Top