📄 说明.txt
字号:
Dim cn As New ADODB.Connection
Dim Cmd As New ADODB.Command
Dim CONSTR As String
CONSTR = "Driver={Microsoft Access Driver (*.mdb)}; DBQ= " & App.Path & "\招聘信息.mdb "
cn.Open CONSTR
Set Cmd.ActiveConnection = cn
'
Cmd.CommandText = "ALTER TABLE tblXUESHENG drop COLUMN " & Trim(Text1.Text)
Cmd.Execute
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\招聘信息.mdb;Persist Security Info=False"
qSTR = ""
from tblXUESHENG
Dim i As Integer
For i = 1 To cMAx - 1
Load txtFields(i)
txtFields(i).Left = txtFields(i - 1).Left
txtFields(i).Top = txtFields(i - 1).Top + txtFields(i - 1).Height + 25
txtFields(i).Visible = True
'
Load lblLabels(i)
lblLabels(i).Left = lblLabels(i - 1).Left
lblLabels(i).Top = lblLabels(i - 1).Top + lblLabels(i - 1).Height + 25
Adodc2.Recordset.MoveNext
lblLabels(i).Caption = Adodc2.Recordset.Fields(0)
lblLabels(i).Visible = True
Next
For i = 0 To cMAx - 1
If Adodc1.Recordset.Fields(i) <> "" Then
txtFields(i).Text = Trim(Adodc1.Recordset.Fields(i))
Else
txtFields(i).Text = ""
End If
Next i
]
VB中打印ACCESS报表
Dim acc As Object
Set acc = CreateObject("Access.Application")
If Right$(Trim$(App.Path), 1) = "\" Then
acc.OpenCurrentDatabase App.Path & "data.mdb"
'打开数据库
Else
acc.OpenCurrentDatabase App.Path & "\data.mdb"
End If
acc.docmd.OpenReport "打印准考证" ', acPreview
打印报表“打印准考证”
acc.Quit
Set acc = Nothing使用ACCESS报表主要缺点就是不能预览(完)计算机基础教程
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -