Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default CHECKBOX HELP

I have a document with a series of checkboxes, checkbox1-20.

I am trying to write code that will go through these checkboxes, and
if they are checked, output a "1" to another file. Can anyone help me
write this code? I tried:

If checkbox1.Checked = true Then
Workbooks("wb1").Worksheets("data").cells(1,1) = 1

This doesn't appear to be working.

Thanks.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9,101
Default CHECKBOX HELP

Cechboxes are not part of cells. They sit onto of cells like pictures. try
soething like this

Sub Macro1()
'
' Macro1 Macro

'

'
For Each Shape In ActiveSheet.Shapes

If Left(Shape.Name, 8) = "CheckBox" Then

MsgBox (Shape.Name)
End If
Next Shape
End Sub

" wrote:

I have a document with a series of checkboxes, checkbox1-20.

I am trying to write code that will go through these checkboxes, and
if they are checked, output a "1" to another file. Can anyone help me
write this code? I tried:

If checkbox1.Checked = true Then
Workbooks("wb1").Worksheets("data").cells(1,1) = 1

This doesn't appear to be working.

Thanks.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
checkbox Jean-Paul Excel Discussion (Misc queries) 0 April 29th 08 02:20 PM
How to have Checkbox A uncheck with checked Checkbox B Texas Aggie Excel Discussion (Misc queries) 3 July 20th 07 10:58 PM
link a checkbox in a sheet to a checkbox on a userform? Arjan Excel Programming 0 November 10th 06 01:37 PM
How do I link one checkbox to update another checkbox? Mike Excel Programming 3 April 28th 06 02:22 AM
checkbox on form reset from checkbox on sheet raw[_12_] Excel Programming 1 December 3rd 05 05:08 AM


All times are GMT +1. The time now is 12:36 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"