View Full Version : Access form to Excel Checkbox
zoro85
09-04-2005, 08:38 AM
I created my checkboxes by looping but then how can i retrieve back my checkbox true or false by looping ?
Set chk = .Checkboxes.Add(g, e, 80, 10)
chk.Text = d
chk.Name = "Q" & h & "chkbox" & chkbox & "Ans" & An
g = g + 50
chkbox = chkbox + 1
geekgirlau
09-19-2005, 02:51 AM
Hi Zoro,
It's hard to work out from your code exactly what your naming convention is because we can't see the value of most of your variables. However you can loop through the checkboxes either by number (for example ".Checkboxes(1)") or by name (for example ".Controls("myCheckboxname")" - the loop will work depending on your naming convention).
Can you provide an example of the names of the checkboxes?
I've also edited your post to make your code a bit easier to read - when you post code, select the text then click on the "VBA" button for format it correctly.
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.