【VB开源代码栏目提醒】:网学会员,鉴于大家对VB开源代码十分关注,论文会员在此为大家搜集整理了“E奖惩录入.frm”一文,供大家参考学习!
VERSION 5.00
Object = "{86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomct2.ocx"
Begin VB.Form E奖惩录入
Caption = "奖惩录入"
ClientHeight = 4005
ClientLeft = 60
ClientTop = 345
ClientWidth = 8295
LinkTopic = "Form1"
ScaleHeight = 4005
ScaleWidth = 8295
StartUpPosition = 3 'Windows Default
Begin VB.Frame Frame
Caption = "奖惩录入"
Height = 3735
Index = 0
Left = 120
TabIndex = 0
Top = 120
Width = 8175
Begin VB.Frame FrameList
Caption = "学生奖惩信息列表"
Height = 3375
Left = 120
TabIndex = 15
Top = 240
Width = 2175
Begin VB.ListBox ListJCxx
Height = 2400
ItemData = "E奖惩录入.frx":0000
Left = 120
List = "E奖惩录入.frx":0007
TabIndex = 16
Top = 600
Width = 1935
End
Begin VB.Label LblNotes
Height = 375
Left = 120
TabIndex = 17
Top = 240
Width = 1935
End
End
Begin VB.Frame FrameInfo
Caption = "奖惩信息"
Height = 3375
Left = 2400
TabIndex = 1
Top = 240
Width = 5655
Begin VB.TextBox txtDep
Height = 375
Left = 3360
TabIndex = 20
Top = 960
Width = 1935
End
Begin VB.TextBox txtName
Height = 375
Left = 3360
TabIndex = 19
Top = 480
Width = 1935
End
Begin VB.Frame Frame2
Height = 645
Index = 0
Left = 120
TabIndex = 5
Top = 2640
Width = 5475
Begin VB.CommandButton CmdSave
BackColor = &H00C0C0C0&
Caption = "保存"
Height = 360
Left = 2640
Style = 1 'Graphical
TabIndex = 6
Top = 195
Width = 800
End
Begin VB.CommandButton CmdModify
BackColor = &H00C0C0C0&
Caption = "修改"
Height = 360
Left = 1065
Style = 1 'Graphical
TabIndex = 11
Top = 195
Width = 800
End
Begin VB.CommandButton CmdExit
BackColor = &H00C0C0C0&
Caption = "退出"
Height = 360
Left = 4245
Style = 1 'Graphical
TabIndex = 10
Top = 195
Width = 800
End
Begin VB.CommandButton CmdCancel
BackColor = &H00C0C0C0&
Caption = "取消"
Height = 360
Left = 3450
Style = 1 'Graphical
TabIndex = 9
Top = 195
Width = 800
End
Begin VB.CommandButton CmdDelete
BackColor = &H00C0C0C0&
Caption = "删除"
Height = 360
Left = 1860
Style = 1 'Graphical
TabIndex = 8
Top = 195
Width = 800
End
Begin VB.CommandButton CmdAdd
BackColor = &H00C0C0C0&
Caption = "添加"
Height = 360
Left = 255
Style = 1 'Graphical
TabIndex = 7
Top = 195
Width = 800
End
End
Begin VB.TextBox txtReason
Height = 855
Left = 840
MaxLength = 50
MultiLine = -1 'True
ScrollBars = 2 'Vertical
TabIndex = 4
Top = 1560
Width = 4455
End
Begin VB.ComboBox CboSelect
Height = 315
Left = 840
TabIndex = 3
Top = 480
Width = 1695
End
Begin MSComCtl2.DTPicker DTPicker1
Height = 375
Left = 840
TabIndex = 2
Top = 960
Width = 1695
_ExtentX = 2990
_ExtentY = 661
_Version = 393216
Format = 66977793
CurrentDate = 38891
End
Begin VB.Label Label1
Caption = "单位:"
Height = 375
Index = 1
Left = 2640
TabIndex = 21
Top = 1080
Width = 855
End
Begin VB.Label Label1
Caption = "名称:"
Height = 375
Index = 0
Left = 2640
TabIndex = 18
Top = 600
Width = 855
End
Begin VB.Label Label5
Caption = "类别:"
Height = 255
Index = 1
Left = 120
TabIndex = 14
Top = 480
Width = 615
End
Begin VB.Label Label7
Caption = "日期:"
Height = 375
Index = 1
Left = 120
TabIndex = 13
Top = 1080
Width = 975
End
Begin VB.Label Label5
Caption = "原因:"
Height = 255
Index = 2
Left = 120
TabIndex = 12
Top = 1680
Width = 1335
End
End
End
End
Attribute VB_Name = "E奖惩录入"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim rs As ADODB.Recordset
Dim SQL As String
Dim msg As String
Dim Index As Integer
Dim stuNo As String
Dim flag As String '判断是新增加记录还是修改记录
Private Sub FixData()
Dim Name As String
'显示奖惩具体信息
If ListJCxx.ListCount > 0 Then
Name = Left(Trim(ListJCxx.Text), InStr(Trim(ListJCxx.Text), ":") - 1)
Else
Exit Sub
End If
LblNotes.Caption = stuNo & "号学生奖惩"
'查询数据
rs.MoveFirst
rs.Find ("名称='" & Name & "'")
'显示数据
CboSelect.Text = Trim(rs.Fields("类别"))
txtName.Text = Trim(rs.Fields("名称"))
txtDep.Text = Trim(rs.Fields("单位"))
If IsDate(Trim(rs.Fields("日期"))) Then
DTPicker1.Value = Trim(rs.Fields("日期")) '时间控件
End If
txtReason.Text = Trim(rs.Fields("原因"))
'控件可用性
CmdModify.Enabled = True: CmdD
上一篇:
dataformatdisp.cpp
下一篇:
应用数学学报编辑部联系方式