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

On 12 May, 21:11, merjet wrote:
Here is a macro that puts CheckBoxes in cells A1:A10 of Sheet1 and
makes B1:B10 the LinkedCells. Modify to suit.

Hth,
Merjet

Sub Macro1()
Dim ws As Worksheet
Set ws = Sheets("Sheet1")
Set rng = ws.Range("A1:A10")
For Each c In rng
With ws.OLEObjects.Add( _
ClassType:="Forms.CheckBox.1", _
Link:=False, _
DisplayAsIcon:=False, _
Left:=c.Left, _
Top:=c.Top, _
Width:=c.Width, _
Height:=c.Height)
.Object.Caption = ""
.LinkedCell = c.Offset(0, 1).Address
.Object.Value = False
End With
Next c
End Sub


This is cool, thanks so much.
It solved a lot of problems and my time from manually creating check
boxes.

good work!

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
Multiple checkboxes and aligning Dudedad Excel Discussion (Misc queries) 2 June 26th 07 07:28 PM
Multiple Checkboxes Annie Excel Discussion (Misc queries) 2 June 11th 07 05:06 PM
Multiple Checkboxes Shortcut? Jason Excel Discussion (Misc queries) 1 October 18th 05 08:08 PM
Multiple checkboxes, one macro? pkohler[_10_] Excel Programming 6 July 1st 05 06:54 PM
Multiple checkboxes 1 macro George J Excel Programming 6 October 15th 03 04:50 PM


All times are GMT +1. The time now is 08:51 PM.

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"