📄 module1.bas
字号:
Attribute VB_Name = "Module1"
Global Const ZHCX_DSN = "DSN=ddmis;UID=sa;PWD=mis005;Database=zhcx"
'Global Hiscon As New ADODB.Connection
Global ZHCX As New ADODB.Connection
Global RS As New ADODB.Recordset
Global RS1 As New ADODB.Recordset
Global RS2 As New ADODB.Recordset
Global RS3 As New ADODB.Recordset
Global RS4 As New ADODB.Recordset
Public ID As Integer
Public A As Integer
Public cname As String
Public yhlx As String
Public ZBBC As String
Public GLID As Integer
Public zbjlxh As Integer
Public qhhm As Integer
Sub Main()
frmdl.Show
End Sub
Public Sub Open_link()
On Error Resume Next
ZHCX.CursorLocation = adUseClient
ZHCX.CommandTimeout = 5 * ZHCX.CommandTimeout
ZHCX.ConnectionTimeout = 5 * ZHCX.ConnectionTimeout
ZHCX.Mode = adModeReadWrite
For i = 0 To 30
Err.Clear
ZHCX.Open ZHCX_DSN
If Err.Number = 0 Then Exit For
For j = 0 To 300
DoEvents
Next j
Next i
'ZHCX.CursorLocation = adUseClient
'ZHCX.Open ZHCX_DSN
End Sub
Public Sub Close_link()
On Error Resume Next
'Hiscon.Close
If ZHCX.State Then
ZHCX.Close
End If
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -