module1.bas

来自「针对矿山企业安全相关法律开发的企业考核评价系统」· BAS 代码 · 共 39 行

BAS
39
字号
Attribute VB_Name = "Module1"
Public sysDB As Database
Public dbPath As String
Public EnterpriseName As String
Public EnterpriseRS As Recordset
Public bFrmShow As Boolean, ErsOpened As Boolean
Public Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Public Const GWL_HWNDPARENT = (-8)
Sub Main()
On Error GoTo errh
 frmSplash.Show
 DoEvents
 SecDelay (2)
 frmMain.Show
 DoEvents
 Unload frmSplash
 Exit Sub
errh:
MsgBox Err.Description & "(" & Err.Number & ")", vbCritical, App.Title & "Error"
End Sub

Public Sub SecDelay(ByVal iSeconds As Integer)
 On Error Resume Next
 Dim sngStartTime As Single
 sngStartTime = Timer
 Do While (Timer - sngStartTime) < iSeconds
    DoEvents
 Loop
End Sub

Public Function ShortLine(ByVal LineNumber As Integer) As String
    Dim i As Integer
    Dim StrLine As String
    For i = 1 To LineNumber
        StrLine = StrLine & "-"
    Next i
   ShortLine = StrLine
End Function

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?