LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default Counting/Changing multiple buttons?

I'm making a userform, and with each userform everything gets more complete
with more options.

An example was a recent one with 21 togglebuttons.

What i'm wanting to be able to do is to easy change all the togglebuttons to
FALSE, or count how many are on true.
To switch them all i've had to put a line of code for each, setting them to
false individually.
To count them all I've had to set a variable, and check each one
individually, and if its TRUE add 1 to the variable.

Is there a simple way to either use a global command to change/count every
togglebutton, or a simple way to loop through them all?

sub change()
for each togglebox in userform
let value = false
next
end sub

sub change()
for i = 1 to 21
let togglebox & i value = false
next
end sub

Are a couple of things I tried unsuccessfully...
 
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
Changing Border buttons on the toolbar Fozzie Bear Excel Discussion (Misc queries) 1 September 14th 07 04:40 PM
changing the way buttons look Don Guillett Excel Programming 0 January 22nd 07 11:48 PM
Excel - Buttons Changing Format KMH Excel Discussion (Misc queries) 1 September 14th 06 05:34 PM
Counting selected option buttons in column? -JEFF-[_2_] Excel Programming 5 August 26th 05 03:23 AM
changing the color of the buttons Mr. V Excel Discussion (Misc queries) 4 April 5th 05 02:57 PM


All times are GMT +1. The time now is 06:38 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"