📄 frmmemberedit.frm
字号:
VERSION 5.00
Begin VB.Form FrmMemberEdit
Caption = "编辑家庭成员信息"
ClientHeight = 3570
ClientLeft = 60
ClientTop = 345
ClientWidth = 4260
LinkTopic = "Form1"
ScaleHeight = 3570
ScaleWidth = 4260
StartUpPosition = 2 '屏幕中心
Begin VB.TextBox txtJob
Height = 330
Left = 1320
TabIndex = 11
Top = 2325
Width = 2415
End
Begin VB.ComboBox cob_Sex
Height = 300
Left = 1320
TabIndex = 8
Top = 802
Width = 1335
End
Begin VB.CommandButton Cmd_Cancel
Caption = "取 消"
Height = 375
Left = 2280
TabIndex = 7
Top = 3000
Width = 1215
End
Begin VB.CommandButton Cmd_OK
Caption = "确 定"
Height = 375
Left = 480
TabIndex = 6
Top = 3000
Width = 1215
End
Begin VB.TextBox txtMobile
Height = 330
Left = 1320
TabIndex = 5
Top = 1289
Width = 2415
End
Begin VB.TextBox txtBirth
Height = 330
Left = 1320
TabIndex = 4
Top = 1806
Width = 1335
End
Begin VB.TextBox txtName
Height = 330
Left = 1320
TabIndex = 3
Top = 285
Width = 1335
End
Begin VB.Label Label5
AutoSize = -1 'True
Caption = "手机"
Height = 180
Left = 720
TabIndex = 10
Top = 1380
Width = 360
End
Begin VB.Label Label4
AutoSize = -1 'True
Caption = "工作单位"
Height = 180
Left = 360
TabIndex = 9
Top = 2400
Width = 720
End
Begin VB.Label Label3
AutoSize = -1 'True
Caption = "出生日期"
Height = 180
Left = 360
TabIndex = 2
Top = 1890
Width = 720
End
Begin VB.Label Label2
AutoSize = -1 'True
Caption = "性别"
Height = 180
Left = 720
TabIndex = 1
Top = 870
Width = 360
End
Begin VB.Label Label1
AutoSize = -1 'True
Caption = "姓名"
Height = 180
Left = 720
TabIndex = 0
Top = 360
Width = 360
End
End
Attribute VB_Name = "FrmMemberEdit"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public OriMId As Long
Public Modify As Boolean
Private Sub Cmd_Cancel_Click()
Unload Me
End Sub
Private Sub Cmd_OK_Click()
If Len(Trim(txtName)) = 0 Then
MsgBox "请输入姓名"
txtName.SetFocus
Exit Sub
End If
With MyMem
.MemName = Trim(txtName)
.Sex = Trim(cob_Sex.Text)
.Birth = Trim(txtBirth)
.Mobile = Trim(txtMobile)
.Job = Trim(txtJob)
If Modify = False Then
.Insert
MsgBox "添加成功"
Else
.Update (OriMId)
MsgBox "修改成功"
End If
End With
Unload Me
End Sub
Private Sub Form_Load()
cob_Sex.AddItem "男", 0
cob_Sex.AddItem "女", 1
cob_Sex.ListIndex = 0
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -