📄 frmopendialog.frm
字号:
VERSION 5.00
Begin VB.Form frmOpenDialog
BorderStyle = 3 'Fixed Dialog
Caption = "打开库中文件"
ClientHeight = 2970
ClientLeft = 45
ClientTop = 330
ClientWidth = 4680
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 2970
ScaleWidth = 4680
ShowInTaskbar = 0 'False
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton Command2
Caption = "取消(&C)"
Height = 405
Left = 3540
TabIndex = 2
Top = 720
Width = 1065
End
Begin VB.CommandButton Command1
Caption = "打开(&O)"
Height = 405
Left = 3540
TabIndex = 1
Top = 90
Width = 1065
End
Begin VB.ListBox List1
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 2940
Left = 0
TabIndex = 0
Top = 0
Width = 3435
End
End
Attribute VB_Name = "frmOpenDialog"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim fo_rs As ADODB.Recordset
Public FileName As String
Private Sub Command1_Click()
FileName = List1.List(List1.ListIndex)
Me.Hide
End Sub
Private Sub Command2_Click()
FileName = ""
Me.Hide
End Sub
Private Sub Form_Load()
Set fo_rs = New ADODB.Recordset
fo_rs.Open "文章表", g_DBCon, adOpenStatic, adLockReadOnly, adCmdTable
Do While Not fo_rs.EOF
List1.AddItem fo_rs.Fields.Item("文章名").Value
fo_rs.MoveNext
Loop
fo_rs.Close
Set fo_rs = Nothing
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -