?? frm_sqjz_cjry.frm
字號:
Width = 735
End
Begin VB.TextBox Text10
Height = 300
Left = 1080
TabIndex = 2
Top = 2160
Width = 1630
End
Begin VB.TextBox Text11
Height = 300
Left = 3720
TabIndex = 1
Top = 2160
Width = 3135
End
Begin MSComCtl2.DTPicker DTPicker1
Height = 300
Left = 1080
TabIndex = 12
Top = 720
Width = 1335
_ExtentX = 2355
_ExtentY = 529
_Version = 393216
Format = 48627713
CurrentDate = 38157
End
Begin VB.Label Label1
Caption = "姓 名"
Height = 255
Left = 240
TabIndex = 29
Top = 360
Width = 855
End
Begin VB.Label Label2
Caption = "身份證號"
Height = 255
Left = 2880
TabIndex = 28
Top = 360
Width = 855
End
Begin VB.Label Label3
Caption = "性 別"
Height = 255
Left = 5280
TabIndex = 27
Top = 360
Width = 735
End
Begin VB.Label Label4
Caption = "出生日期"
Height = 255
Left = 240
TabIndex = 26
Top = 840
Width = 855
End
Begin VB.Label Label5
Caption = "文化程度"
Height = 255
Left = 2880
TabIndex = 25
Top = 840
Width = 855
End
Begin VB.Label Label6
Caption = "婚姻狀況"
Height = 375
Left = 5280
TabIndex = 24
Top = 840
Width = 855
End
Begin VB.Label Label7
Caption = "樓 號"
Height = 375
Left = 240
TabIndex = 23
Top = 1320
Width = 975
End
Begin VB.Label Label8
Caption = "戶 號"
Height = 375
Left = 2880
TabIndex = 22
Top = 1320
Width = 855
End
Begin VB.Label Label9
Caption = "家庭人數"
Height = 375
Left = 5280
TabIndex = 21
Top = 1320
Width = 855
End
Begin VB.Label Label10
Caption = "經濟狀況"
Height = 255
Left = 240
TabIndex = 20
Top = 1800
Width = 735
End
Begin VB.Label Label11
Caption = "住所類型"
Height = 255
Left = 2880
TabIndex = 19
Top = 1800
Width = 735
End
Begin VB.Label Label12
Caption = "月 收 入"
Height = 255
Left = 5280
TabIndex = 18
Top = 1800
Width = 735
End
Begin VB.Label Label13
Caption = "家庭電話"
Height = 255
Left = 240
TabIndex = 17
Top = 2280
Width = 855
End
Begin VB.Label Label14
Caption = "住 址"
Height = 255
Left = 2880
TabIndex = 16
Top = 2280
Width = 735
End
End
End
Attribute VB_Name = "frm_SQJZ_CJRY"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Cmd_add_Click()
Call main
If Text12.Text = "" Then
MsgBox "輸入不能為空"
Else
frm_CZRK_HKB.Adodc1.RecordSource = "select * from Table_HKB where 姓名='" + Text1.Text + "'"
frm_CZRK_HKB.Adodc1.Refresh
If frm_CZRK_HKB.Adodc1.Recordset.RecordCount > 0 Then
frm_SQJZ_ZB.Adodc1.RecordSource = "select * from Table_SQJZ_CJRB where 殘疾證號='" + Text12.Text + "'"
frm_SQJZ_ZB.Adodc1.Refresh
If frm_SQJZ_ZB.Adodc1.Recordset.RecordCount > 0 Then
MsgBox "此人的信息已經存在,輸入不能繼續", 48, "提示"
Else
Text16.Text = frm_CZRK_HKB.Adodc1.Recordset.Fields("人口編號")
Set adoRs = adoCon.Execute("insert into Table_SQJZ_CJRB values(" & Text12 & ",'" & Text16 & "','" & Text1 & "','" & Text2 & "','" & Combo1 & "','" & DTPicker1 & "','" & Text3 & "','" & Combo2 & "','" & Combo3 & "','" & Text4 & "','" & Text5 & "','" & Text6 & "','" & Text7 & "','" & Text8 & "','" & Text9 & "','" & Text10 & "','" & Text11 & "','" & Combo4 & "','" & Text15 & "','" & Combo5 & "','" & Text13 & "','" & tet14 & "')")
MsgBox "數據保存成功!", 32, "人口信息管理系統"
Unload Me
frm_SQJZ_ZB.Adodc1.Refresh
End If
Else
MsgBox "數據庫中沒有此人的信息", 48, "提示"
End If
End If
adoCon.Close
End Sub
Private Sub Cmd_cancel_Click()
Unload Me
End Sub
Private Sub Cmd_QD_Click()
End Sub
Private Sub Cmd_select_Click()
frm_SQJZ_ryxz.Show
End Sub
Private Sub Combo4_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
Text15.SetFocus
Else
End If
End Sub
Private Sub Combo5_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
Text13.SetFocus
Else
End If
End Sub
Private Sub Form_Load()
Me.Left = (Screen.Width - Me.Width) / 2
Me.Top = (Screen.Height - Me.Height) / 2
End Sub
Private Sub Text12_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
Dim StrInput, Temp As String
Dim i, Length As Integer
i = 1
StrInput = Text12.Text
Length = Len(StrInput)
If Text12.Text = "" Then
MsgBox "輸入不能為空", , "提示"
Text12.SetFocus
Else
Do While (i <= Length)
Temp = Mid$(StrInput, i, 1)
If Asc(Temp) < 48 Or Asc(Temp) > 57 Then
If i = 1 Then
MsgBox "輸入數據非法!!", , "提示"
Else
End If
Text12.Text = ""
Text12.SetFocus
Else
End If
i = i + 1
Loop
If Text12.Text = "" Then
Text12.SetFocus
Else
Combo4.SetFocus
End If
End If
Else
End If
End Sub
Private Sub Text13_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
Text14.SetFocus
Else
End If
End Sub
Private Sub Text15_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 Then
Combo5.SetFocus
Else
End If
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -