📄 form1f.frm
字号:
Left = 2160
TabIndex = 5
Top = 600
Width = 195
_ExtentX = 344
_ExtentY = 661
_Version = 393216
Value = 1
BuddyControl = "Text3"
BuddyDispid = 196632
OrigLeft = 720
OrigTop = 120
OrigRight = 915
OrigBottom = 495
Max = 15
Min = 1
SyncBuddy = -1 'True
BuddyProperty = 65547
Enabled = -1 'True
End
Begin MSComCtl2.UpDown UpDown4
Height = 375
Left = 3000
TabIndex = 7
Top = 600
Width = 195
_ExtentX = 344
_ExtentY = 661
_Version = 393216
Value = 1
BuddyControl = "Text4"
BuddyDispid = 196631
OrigLeft = 720
OrigTop = 120
OrigRight = 915
OrigBottom = 495
Max = 15
Min = 1
SyncBuddy = -1 'True
BuddyProperty = 65547
Enabled = -1 'True
End
Begin MSComCtl2.UpDown UpDown5
Height = 375
Left = 3840
TabIndex = 9
Top = 600
Width = 195
_ExtentX = 344
_ExtentY = 661
_Version = 393216
Value = 1
BuddyControl = "Text5"
BuddyDispid = 196630
OrigLeft = 720
OrigTop = 120
OrigRight = 915
OrigBottom = 495
Max = 15
Min = 1
SyncBuddy = -1 'True
BuddyProperty = 65547
Enabled = -1 'True
End
Begin MSComCtl2.UpDown UpDown6
Height = 975
Left = 4680
TabIndex = 11
Top = 600
Width = 195
_ExtentX = 344
_ExtentY = 1720
_Version = 393216
Value = 1
BuddyControl = "Text6"
BuddyDispid = 196629
OrigLeft = 720
OrigTop = 120
OrigRight = 915
OrigBottom = 495
Max = 15
Min = 1
SyncBuddy = -1 'True
BuddyProperty = 65547
Enabled = -1 'True
End
Begin MSComCtl2.UpDown UpDown7
Height = 975
Left = 5400
TabIndex = 13
Top = 600
Width = 195
_ExtentX = 344
_ExtentY = 1720
_Version = 393216
Value = 1
BuddyControl = "Text7"
BuddyDispid = 196628
OrigLeft = 720
OrigTop = 120
OrigRight = 915
OrigBottom = 495
Max = 15
Min = 1
SyncBuddy = -1 'True
BuddyProperty = 65547
Enabled = -1 'True
End
Begin MSComCtl2.UpDown UpDown8
Height = 375
Left = 345
TabIndex = 15
Top = 120
Width = 195
_ExtentX = 344
_ExtentY = 661
_Version = 393216
Value = 1
BuddyControl = "Text8"
BuddyDispid = 196627
OrigLeft = 720
OrigTop = 120
OrigRight = 915
OrigBottom = 495
Max = 15
Min = 1
SyncBuddy = -1 'True
BuddyProperty = 65547
Enabled = -1 'True
End
Begin VB.Label Label13
Caption = "Label13"
Height = 375
Left = 4200
TabIndex = 53
Top = 3480
Width = 1095
End
Begin VB.Label Label12
Caption = "Label12"
Height = 375
Left = 4080
TabIndex = 52
Top = 4080
Width = 1215
End
Begin VB.Label Label11
Caption = "Label11"
Height = 375
Left = 3960
TabIndex = 51
Top = 4680
Width = 1095
End
Begin VB.Label Label10
Caption = "一等奖"
Height = 375
Left = 3000
TabIndex = 50
Top = 3600
Width = 975
End
Begin VB.Label Label9
Caption = "二等奖"
Height = 495
Left = 3000
TabIndex = 49
Top = 4080
Width = 855
End
Begin VB.Label Label8
Caption = "三等奖"
Height = 375
Left = 3120
TabIndex = 48
Top = 4680
Width = 615
End
Begin VB.Label Label7
Caption = "Label7"
Height = 375
Left = 3960
TabIndex = 47
Top = 5280
Width = 1095
End
Begin VB.Label Label6
Caption = "四等奖"
Height = 255
Left = 3120
TabIndex = 46
Top = 5280
Width = 735
End
Begin VB.Label Label5
Caption = "Label5"
Height = 375
Left = 4080
TabIndex = 45
Top = 5760
Width = 1095
End
Begin VB.Label Label4
Caption = "五等奖"
Height = 375
Left = 3120
TabIndex = 44
Top = 5760
Width = 855
End
Begin VB.Label Label3
Caption = "六等奖"
Height = 375
Left = 3120
TabIndex = 43
Top = 6240
Width = 855
End
Begin VB.Label Label2
Caption = "Label2"
Height = 375
Left = 4080
TabIndex = 42
Top = 6240
Width = 1095
End
End
Attribute VB_Name = "test"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim start As Boolean
Dim i As Integer
Private Sub Command1_Click()
start = True
End Sub
Private Sub Command2_Click()
start = False
End Sub
Private Sub Command3_Click() '结果
Dim s As Integer
Dim z1 As Double
Dim z2 As Long
Dim z3 As Long
z1 = 1
z2 = 1
z3 = 1
For s = 1 To Val(Trim(Text16.Text))
z1 = z1 * s
Next s
For s = 1 To Val(Trim(Text17.Text))
z2 = z2 * s
Next s
For s = 1 To Val(Trim(Text16.Text)) - Val(Trim(Text17.Text))
z3 = z3 * s
Next s
Dim z4 As Long
z4 = z1 / (z2 * z3)
Text18.Text = Str(z4)
End Sub
Private Sub Command4_Click()
'位频统计
Adodc3.Recordset.MoveFirst
Do While Not Adodc3.Recordset.EOF
For i = 1 To 8
Adodc3.Recordset.Fields(i).Value = 0
Adodc3.Recordset.Update
Next i
Adodc3.Recordset.MoveNext
Loop
Adodc3.Recordset.Resync
Adodc3.Refresh
Adodc2.Recordset.MoveFirst
Do While Not Adodc2.Recordset.EOF
For i = 1 To 8
Adodc3.Recordset.MoveFirst
Adodc3.Recordset.Find "号码球='" & Adodc2.Recordset.Fields(i).Value & "'", , adSearchForward, 1
Adodc3.Recordset.Fields(i).Value = Adodc3.Recordset.Fields(i).Value + 1
Adodc3.Recordset.Update
Next i
Adodc2.Recordset.MoveNext
Loop
Adodc3.Recordset.Resync
End Sub
Private Sub Command5_Click()
'和筛选
Dim summ As Integer
summ = 0
Adodc4.Recordset.MoveFirst
Do While Not Adodc4.Recordset.EOF
For i = 1 To 7
summ = summ + Val(Adodc4.Recordset.Fields(i).Value)
Next i
If summ < 70 Or summ > 160 Then
Adodc4.Recordset.Delete
Adodc4.Recordset.Update
End If
Adodc4.Recordset.MoveNext
summ = 0
Loop
Adodc4.Recordset.Resync adAffectAllChapters, adResyncAllValues
Adodc4.Refresh
DoEvents
Adodc4.Refresh
End Sub
Private Sub Command6_Click()
Adodc5.Recordset.Filter = adFilterNone
Dim s1 As Integer
Dim s2 As Integer
Dim s3 As Integer
Dim s4 As Integer
Dim s5 As Integer
Dim s6 As Integer
Dim s7 As Integer
Dim s8 As Integer
s1 = 0
s2 = 0
s3 = 0
s4 = 0
s5 = 0
s6 = 0
s7 = 0
s8 = 0
Adodc5.Recordset.Filter = "七<=8"
Adodc5.Recordset.MoveFirst
Do While Not Adodc5.Recordset.EOF
If Adodc5.Recordset.Fields(1).Value = 1 Or Adodc5.Recordset.Fields(2).Value = 1 Or Adodc5.Recordset.Fields(3).Value = 1 Or Adodc5.Recordset.Fields(4).Value = 1 Or Adodc5.Recordset.Fields(5).Value = 1 Or Adodc5.Recordset.Fields(6).Value = 1 Or Adodc5.Recordset.Fields(7).Value = 1 Then
s1 = s1 + 1
End If
If Adodc5.Recordset.Fields(1).Value = 3 Or Adodc5.Recordset.Fields(2).Value = 3 Or Adodc5.Recordset.Fields(3).Value = 3 Or Adodc5.Recordset.Fields(4).Value = 3 Or Adodc5.Recordset.Fields(5).Value = 3 Or Adodc5.Recordset.Fields(6).Value = 3 Or Adodc5.Recordset.Fields(7).Value = 3 Then
s1 = s1 + 1
End If
If Adodc5.Recordset.Fields(1).Value = 5 Or Adodc5.Recordset.Fields(2).Value = 5 Or Adodc5.Recordset.Fields(3).Value = 5 Or Adodc5.Recordset.Fields(4).Value = 5 Or Adodc5.Recordset.Fields(5).Value = 5 Or Adodc5.Recordset.Fields(6).Value = 5 Or Adodc5.Recordset.Fields(7).Value = 5 Then
s1 = s1 + 1
End If
If Adodc5.Recordset.Fields(1).Value = 7 Or Adodc5.Recordset.Fields(2).Value = 7 Or Adodc5.Recordset.Fields(3).Value = 7 Or Adodc5.Recordset.Fields(4).Value = 7 Or Adodc5.Recordset.Fields(5).Value = 7 Or Adodc5.Recordset.Fields(6).Value = 7 Or Adodc5.Recordset.Fields(7).Value = 7 Then
s1 = s1 + 1
End If
' If Adodc5.Recordset.Fields(1).Value = 2 Or Adodc5.Recordset.Fields(2).Value = 2 Or Adodc5.Recordset.Fields(3).Value = 2 Or Adodc5.Recordset.Fields(4).Value = 2 Or Adodc5.Recordset.Fields(5).Value = 2 Or Adodc5.Recordset.Fields(6).Value = 2 Or Adodc5.Recordset.Fields(7).Value = 2 Then
' s1 = s1 + 1
' End If
' If Adodc5.Recordset.Fields(1).Value = 6 Or Adodc5.Recordset.Fields(2).Value = 6 Or Adodc5.Recordset.Fields(3).Value = 6 Or Adodc5.Recordset.Fields(4).Value = 6 Or Adodc5.Recordset.Fields(5).Value = 6 Or Adodc5.Recordset.Fields(6).Value = 6 Or Adodc5.Recordset.Fields(7).Value = 6 Then
' s4 = s4 + 1
' End If
' If Adodc5.Recordset.Fields(1).Value = 4 Or Adodc5.Recordset.Fields(2).Value = 4 Or Adodc5.Recordset.Fields(3).Value = 4 Or Adodc5.Recordset.Fields(4).Value = 4 Or Adodc5.Recordset.Fields(5).Value = 4 Or Adodc5.Recordset.Fields(6).Value = 4 Or Adodc5.Recordset.Fields(7).Value = 4 Then
' s1 = s1 + 1
' End If
' If Adodc5.Recordset.Fields(1).Value = 8 Or Adodc5.Recordset.Fields(2).Value = 8 Or Adodc5.Recordset.Fields(3).Value = 8 Or Adodc5.Recordset.Fields(4).Value = 8 Or Adodc5.Recordset.Fields(5).Value = 8 Or Adodc5.Recordset.Fields(6).Value = 8 Or Adodc5.Recordset.Fields(7).Value = 8 Then
' s1 = s1 + 1
' End If
If s1 = 4 Then
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -