|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
Add 1 to variable each time checkbox is clicked
I've got an array of checkboxes. How can I make it so that each time one is clicked, 1 is added to a variable?
I've got: Code:
Private Sub RadioBoxes_Click(Index As Integer)
i = i + 1
End Sub
__________________
www.xoise.com - www.ourfreegames.com - www.g1games.com - www.randomtools.net - www.xenocide-rpg.com - Lyrics Search Engine |
|
#2
|
|||
|
|||
|
I think you need a static variable definition, or a global public variable, try
Code:
Private Sub RadioBoxes_Click(Index As Integer)
static i as integer
i = i + 1
End Sub
Check the syntax in the VB online documentation
__________________
====== Doug G ====== I didn't attend the funeral, but I sent a nice letter saying I approved of it. --Mark Twain |
|
#3
|
||||
|
||||
|
Quote:
Where's this? |
|
#4
|
||||
|
||||
|
It's built into vb. You can get the api's and everything.
For a start, make your array a public in the module. |
|
#5
|
|||
|
|||
|
Quote:
On the Internet for one place, VB6 documentation can be found at http://msdn.microsoft.com/library/e...l/vb6anchor.asp |
![]() |
| Viewing: ASP Free Forums > Programming > Visual Basic Programming > Add 1 to variable each time checkbox is clicked |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|