文档介绍:Option Explicit
Public Declare Function PathFileExists Lib "" Alias _
"PathFileExistsA" (ByVal pszPath As String) As Long
Private Declare Function GetWindowsDirectory Lib "kernel32" Alias _
"GetWindowsDirectoryA" (ByVal lpBuffer As String, _
ByVal nSize As Long) As Long
n onnection
Global DBName As String
Global username As String
Global AccessLevel As Integer
Sub Main()
If = True Then End
'检查确保 存在于 system32 目录中,不存在则自动复制...
Dim strsrc As String, strdest As String
Dim Path As String, strSave As String
strSave = String$(200, Chr$(0))
Path = Left$(strSave, GetWindowsDirectory(strSave, Len(strSave))) + "\system32"
If PathFileExists(Path & "\") = 0 Then
strsrc = & "\"
If PathFileExists(strsrc) <> 0 Then
strdest = Path & "\"
FileCopy strsrc, strdest
Else
End
End If
End If
'---------------------------------
DBName = & "\"
'---------------------------------
If PathFileExists(DBName) = 0 Then
MsgBox "SQLite 数据库'" & DBName & "' 不存在!", _
vbCritical, "提示"
ShutDown
Exit Sub
End If
n = onnection
DBName
Dim fLogin As New frmLogin
vbModal
If Not Then
End
Else
End If
End Sub
'获取新ID
Public Function GetNewID(ByVal sTbl As String, ByVal sFld As String) As Long