Sorry about that, you can use just the code without the updatelabels. in vb works but in jabaco doesnt do the job
and yes i have 3 option button (array) in a frame
like this
option1(0)
option1(1)
option1(2)
for example:
my code in visual basic when u click on one option1(0) the others are false of course, and if i click again on option1(0) this option come false, and of course the others keep on false state.
i dont use checkbox because is easy when u have 3 frames and 3 option arrays like this option1, option2,option3
then some labels updates later when clicking..
If is possible to make it work on jabaco please i really appreciate it!!
|
Jabaco Source
|
1
2
3
4
5
6
7
8
9
10
11
|
Dim FoundIndex1 As IntegerDim ToggleVal As Boolean
Private Sub Form_Load()FoundIndex1 = -1End Sub
Private Sub Option1_GotFocus(Index As Integer)FoundIndex1 = Index
End Sub
Private Sub Option1_MouseDown(Index As Integer, Button As Integer, Shift As Integer, X As Single, Y As Single)ToggleVal = Option1(Index).ValueEnd Sub
Private Sub Option1_MouseUp(Index As Integer, Button As Integer, Shift As Integer, X As Single, Y As Single)With Option1(Index).Value = .Value Xor ToggleVal 'Toggle the state of the optionIf .Value Then 'If it is selected ThenFoundIndex1 = Index ' Save the indexElse 'Else (not selected)FoundIndex1 = -1 ' Flag as not selected
End IfEnd With
End Sub
|