?? module1.bas
字號:
Attribute VB_Name = "Module1"
'****************************************************************************
'人人為我,我為人人
'枕善居收藏整理
'發布日期:2007/12/17
'描 述:明發-超級大樂透縮水選號器 Ver1.0
'網 站:http://www.Mndsoft.com/ (VB6源碼博客)
'網 站:http://www.VbDnet.com/ (VB.NET源碼博客,主要基于.NET2005)
'e-mail :Mndsoft@163.com
'e-mail :Mndsoft@126.com
'OICQ :88382850
' 如果您有新的好的代碼別忘記給枕善居哦!
'****************************************************************************
Dim Score As Long
Dim AscRand As Long
Dim num1, num2, sum As Double
Public Function Calc(Srt1 As Double, Srt2 As Double, CMD As Integer) As Double
On Error Resume Next
num1 = CDbl(Srt1)
num2 = CDbl(Srt2)
Select Case CMD
Case 1 '+
sum = num1 + num2
Calc = CStr(sum)
Case 2 '-
sum = num1 - num2
Calc = CStr(sum)
Case 3 '*
sum = num1 * num2
Calc = CStr(sum)
Case 4 '/
sum = num1 / num2
Calc = CStr(sum)
End Select
End Function
Function CendRan(Min_Integer As Long, Max_Integer As Long) As Long
Randomize
Score = Rnd * (Max_Integer - Min_Integer) + Min_Integer
CendRan = Score
End Function
Function AscRan(Score_Integer As Long) As Long
Randomize
AscRand = Int(Score_Integer * Rnd)
AscRan = AscRand
End Function
Function OCNum(NumBerIndex) As Boolean
Select Case NumBerIndex
Case "01"
OCNum = False
Case "02"
OCNum = True
Case "03"
OCNum = False
Case "04"
OCNum = True
Case "05"
OCNum = False
Case "06"
OCNum = True
Case "07"
OCNum = False
Case "08"
OCNum = True
Case "09"
OCNum = False
Case "10"
OCNum = True
Case "11"
OCNum = False
Case "12"
OCNum = True
Case "13"
OCNum = False
Case "14"
OCNum = True
Case "15"
OCNum = False
Case "16"
OCNum = True
Case "17"
OCNum = False
Case "18"
OCNum = True
Case "19"
OCNum = False
Case "20"
OCNum = True
Case "21"
OCNum = False
Case "22"
OCNum = True
Case "23"
OCNum = False
Case "24"
OCNum = True
Case "25"
OCNum = False
Case "26"
OCNum = True
Case "27"
OCNum = False
Case "28"
OCNum = True
Case "29"
OCNum = False
Case "30"
OCNum = True
Case "31"
OCNum = False
Case "32"
OCNum = True
Case "33"
OCNum = False
Case "34"
OCNum = True
Case "35"
OCNum = False
End Select
End Function
Function WriteTxtAppend(file1 As String, Text1 As String) As Boolean
On Error GoTo err1
Dim fn As Integer
fn = FreeFile()
Open file1 For Append As #fn
Print #fn, Text1
Close #fn
WriteTxtAppend = True
Exit Function
err1:
WriteTxtAppend = False
End Function
Function ReadTXT(file1 As String) As String
On Error GoTo err1
Dim fn As Integer
Dim ss As String, S As String
fn = FreeFile()
Open file1 For Input As #fn
Do While Not EOF(fn)
Line Input #fn, S
If ss = "" Then
ss = S
Else
ss = ss + Chr(13) + Chr(10) + S
End If
Loop
Close #fn
ReadTXT = ss
Exit Function
err1:
Close #fn
End Function
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -