📄 form3.frm
字号:
VERSION 5.00
Object = "{67397AA1-7FB1-11D0-B148-00A0C922E820}#6.0#0"; "MSADODC.OCX"
Begin VB.Form Form3
Caption = "列车查询"
ClientHeight = 3990
ClientLeft = 60
ClientTop = 450
ClientWidth = 7005
LinkTopic = "Form3"
ScaleHeight = 3990
ScaleWidth = 7005
StartUpPosition = 3 '窗口缺省
Begin VB.TextBox Text7
Height = 375
Left = 2040
TabIndex = 16
Top = 3600
Width = 2055
End
Begin VB.TextBox Text1
Height = 375
Left = 2040
TabIndex = 13
Top = 480
Width = 2055
End
Begin MSAdodcLib.Adodc Adodc1
Height = 375
Left = 4920
Top = 2040
Visible = 0 'False
Width = 1695
_ExtentX = 2990
_ExtentY = 661
ConnectMode = 0
CursorLocation = 3
IsolationLevel = -1
ConnectionTimeout= 15
CommandTimeout = 30
CursorType = 3
LockType = 3
CommandType = 2
CursorOptions = 0
CacheSize = 50
MaxRecords = 0
BOFAction = 0
EOFAction = 0
ConnectStringType= 1
Appearance = 1
BackColor = -2147483643
ForeColor = -2147483640
Orientation = 0
Enabled = -1
Connect = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=网上订票1.mdb;Persist Security Info=False"
OLEDBString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=网上订票1.mdb;Persist Security Info=False"
OLEDBFile = ""
DataSourceName = ""
OtherAttributes = ""
UserName = ""
Password = ""
RecordSource = "时刻表"
Caption = "Adodc1"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
_Version = 393216
End
Begin VB.CommandButton Command1
Caption = "查询"
Height = 615
Left = 4920
TabIndex = 12
Top = 720
Width = 1695
End
Begin VB.CommandButton Command4
Caption = "客户查询"
Height = 615
Left = 4920
TabIndex = 9
Top = 2880
Width = 1815
End
Begin VB.TextBox Text6
DataField = "卧铺价"
DataSource = "Adodc1"
Height = 375
Left = 2040
TabIndex = 8
Top = 3080
Width = 2055
End
Begin VB.TextBox Text5
DataField = "硬座价"
DataSource = "Adodc1"
Height = 375
Left = 2040
TabIndex = 7
Top = 2560
Width = 2055
End
Begin VB.TextBox Text4
DataField = "发车时间"
DataSource = "Adodc1"
Height = 375
Left = 2040
TabIndex = 6
Top = 2040
Width = 2055
End
Begin VB.TextBox Text3
DataField = "终点站"
DataSource = "Adodc1"
Height = 375
Left = 2040
TabIndex = 5
Top = 1520
Width = 2055
End
Begin VB.TextBox Text2
DataField = "起始站"
DataSource = "Adodc1"
Height = 375
Left = 2040
TabIndex = 4
Top = 1000
Width = 2055
End
Begin VB.Label Label8
Caption = "日期"
Height = 255
Left = 240
TabIndex = 15
Top = 3600
Width = 1335
End
Begin VB.Label Label6
Caption = "输入车次查询:"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 0
TabIndex = 14
Top = 120
Width = 1935
End
Begin VB.Label Label7
Caption = "卧铺价"
Height = 255
Left = 240
TabIndex = 11
Top = 3100
Width = 1335
End
Begin VB.Label Label5
Caption = "硬座价"
Height = 255
Left = 240
TabIndex = 10
Top = 2600
Width = 1335
End
Begin VB.Label Label4
Caption = "发车时间"
Height = 255
Left = 240
TabIndex = 3
Top = 2100
Width = 1335
End
Begin VB.Label Label3
Caption = "终点站"
Height = 255
Left = 240
TabIndex = 2
Top = 1600
Width = 1335
End
Begin VB.Label Label2
Caption = "起始站"
Height = 255
Left = 240
TabIndex = 1
Top = 1100
Width = 1335
End
Begin VB.Label Label1
Caption = "车次"
Height = 255
Left = 240
TabIndex = 0
Top = 600
Width = 1335
End
End
Attribute VB_Name = "Form3"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
Adodc1.Recordset.MoveFirst
Do While Adodc1.Recordset.EOF <> True
If Adodc1.Recordset.Fields("车次").Value = Text1.Text Then
Text2.Text = Adodc1.Recordset.Fields("起始站").Value
Text3.Text = Adodc1.Recordset.Fields("终点站").Value
Text4.Text = Adodc1.Recordset.Fields("发车时间").Value
Text5.Text = Adodc1.Recordset.Fields("硬座价").Value
Text6.Text = Adodc1.Recordset.Fields("卧铺价").Value
Text7.Text = Adodc1.Recordset.Fields("日期").Value
Exit Do
End If
Adodc1.Recordset.MoveNext
Loop
If Adodc1.Recordset.EOF <> False Then
MsgBox ("没有此趟列车!!")
End If
End Sub
Private Sub Command4_Click()
Form4.Show
Hide
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -