|
-
Nov 28th, 1999, 05:36 PM
#1
Thread Starter
Lively Member
Ok My Problem Is I Have 4 Option Buttons And 1 command button but I want it to ignore what the command button does normally when one of the option buttons is selected how do i do that?
I can get it so it does the option i select as well as what is already in the command button but it won't ignore what's already in the command button can someone give me a full example how to do this?
-
Nov 28th, 1999, 05:57 PM
#2
Member
If my understanding of your problem is that when one of your 4 option buttons is selected you do one thing and if nothing is selected you do something else, here's a quick snippet...
Private Sub Command1_Click()
Dim iCount As Integer, bSelect As Boolean
' this assumes your option buttons are a control array called "Option1"
For iCount = 0 to 3
If Option1(iCount).Value Then
bSelect = True
Exit For
End If
Next
If bSelect = True Then
' add your code for when an option is selected
Else
' add code for when no option is selected
End If
End Sub
------------------
* * * * * * * * * * * * * * * * * * * * * *
* *
* AndyC *
* London *
* email: [email protected] *
* *
* * * * * * * * * * * * * * * * * * * * * *
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|