📄 form3.frm
字号:
VERSION 5.00
Begin VB.Form Form3
Caption = "员工婚姻状况"
ClientHeight = 4650
ClientLeft = 60
ClientTop = 450
ClientWidth = 6510
LinkTopic = "Form3"
ScaleHeight = 4650
ScaleWidth = 6510
StartUpPosition = 3 '窗口缺省
Begin VB.TextBox Text2
Height = 375
Left = 2160
TabIndex = 16
Top = 2760
Width = 2415
End
Begin VB.CommandButton Command4
Caption = "|<"
Height = 495
Left = 2040
TabIndex = 14
Top = 3240
Width = 615
End
Begin VB.CommandButton Command5
Caption = "<"
Height = 495
Left = 2655
TabIndex = 13
Top = 3240
Width = 615
End
Begin VB.CommandButton Command6
Caption = ">"
Height = 495
Left = 3270
TabIndex = 12
Top = 3240
Width = 615
End
Begin VB.CommandButton Command7
Caption = ">|"
Height = 495
Left = 3885
Style = 1 'Graphical
TabIndex = 11
Top = 3240
Width = 615
End
Begin VB.CommandButton Command3
Caption = "退出"
Height = 495
Left = 5040
TabIndex = 10
Top = 4080
Width = 1215
End
Begin VB.CommandButton Command2
Caption = "更新"
Height = 495
Left = 3000
TabIndex = 9
Top = 4080
Width = 1215
End
Begin VB.CommandButton Command1
Caption = "添加"
Height = 495
Left = 720
TabIndex = 8
Top = 4080
Width = 1215
End
Begin VB.TextBox Text5
Height = 375
Left = 2160
TabIndex = 7
Top = 2160
Width = 2295
End
Begin VB.TextBox Text4
Height = 375
Left = 2160
TabIndex = 6
Top = 1560
Width = 2295
End
Begin VB.TextBox Text3
Height = 375
Left = 2160
TabIndex = 5
Top = 960
Width = 2295
End
Begin VB.TextBox Text1
Height = 375
Left = 2160
TabIndex = 4
Top = 360
Width = 2295
End
Begin VB.Label Label2
Caption = "备注"
Height = 495
Left = 1080
TabIndex = 15
Top = 2880
Width = 855
End
Begin VB.Label Label5
Caption = "工作单位"
Height = 375
Left = 1080
TabIndex = 3
Top = 2160
Width = 1695
End
Begin VB.Label Label4
Caption = "配偶名称"
Height = 375
Left = 1080
TabIndex = 2
Top = 1560
Width = 1695
End
Begin VB.Label Label3
Caption = "婚姻状况"
Height = 375
Left = 1080
TabIndex = 1
Top = 960
Width = 1695
End
Begin VB.Label Label1
Caption = "编号"
Height = 375
Left = 1080
TabIndex = 0
Top = 360
Width = 1695
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()
If Text1.Text <> "" Then
Form1.Adodc1.Recordset.AddNew
Else
a = MsgBox("请输入编号信息", , "警告")
End If
End Sub
Private Sub Command4_Click()
Form1.Adodc1.Refresh
Form1.Adodc1.Recordset.MoveFirst
End Sub
Private Sub Command5_Click()
If Not Form1.Adodc1.Recordset.BOF Then
Form1.Adodc1.Recordset.MovePrevious
End If
End Sub
Private Sub Command6_Click()
If Not Form1.Adodc1.Recordset.EOF Then
Form1.Adodc1.Recordset.MoveNext
End If
End Sub
Private Sub Command7_Click()
Form1.Adodc1.Refresh
Form1.Adodc1.Recordset.MoveLast
End Sub
Private Sub Command2_Click()
If Text1.Text = "" Then
MsgBox ("请选择数据")
Else
a = MsgBox("确认要更新!", 1, "警告")
End If
If a = 1 Then Form1.Adodc1.Recordset.Update
End Sub
Private Sub Command3_Click()
Unload Me
End Sub
Private Sub Form_Load()
Form1.Adodc1.RecordSource = "员工婚姻状况表"
Form1.Adodc1.Refresh
Set Text1.DataSource = Form1.Adodc1
Text1.DataField = "编号"
Set Text2.DataSource = Form1.Adodc1
Text2.DataField = "备注"
Set Text3.DataSource = Form1.Adodc1
Text3.DataField = "婚姻状况"
Set Text4.DataSource = Form1.Adodc1
Text4.DataField = "配偶名称"
Set Text5.DataSource = Form1.Adodc1
Text5.DataField = "工作单位"
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -