⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 frmstuperupdate.frm

📁 这是一个选课系统
💻 FRM
📖 第 1 页 / 共 2 页
字号:
      Left            =   720
      TabIndex        =   7
      Top             =   3000
      Width           =   975
   End
   Begin VB.Label Label5 
      BackStyle       =   0  'Transparent
      Caption         =   "出生年月:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   12
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   3720
      TabIndex        =   5
      Top             =   2880
      Width           =   1095
   End
   Begin VB.Label Label4 
      BackStyle       =   0  'Transparent
      Caption         =   "性  别:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   12
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   720
      TabIndex        =   4
      Top             =   2280
      Width           =   975
   End
   Begin VB.Label Label3 
      BackStyle       =   0  'Transparent
      Caption         =   "姓   名:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   12
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   3720
      TabIndex        =   3
      Top             =   1560
      Width           =   1095
   End
   Begin VB.Label Label2 
      BackStyle       =   0  'Transparent
      Caption         =   "学  号:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   12
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   720
      TabIndex        =   2
      Top             =   1560
      Width           =   975
   End
   Begin VB.Image imgTitleMaximize 
      Height          =   195
      Left            =   6240
      Picture         =   "frmstuperupdate.frx":0472
      ToolTipText     =   "Maximize (Disabled)"
      Top             =   360
      Visible         =   0   'False
      Width           =   195
   End
   Begin VB.Image imgTitleclose 
      Height          =   195
      Left            =   7080
      Picture         =   "frmstuperupdate.frx":06BC
      ToolTipText     =   "Close"
      Top             =   240
      Width           =   195
   End
   Begin VB.Image imgTitleHelp 
      Height          =   210
      Left            =   6600
      Picture         =   "frmstuperupdate.frx":0906
      Stretch         =   -1  'True
      Top             =   120
      Width           =   210
   End
   Begin VB.Image imgTitleMinimize 
      Height          =   210
      Left            =   6840
      Picture         =   "frmstuperupdate.frx":0B50
      Stretch         =   -1  'True
      Top             =   120
      Width           =   210
   End
   Begin VB.Label lblTitle 
      AutoSize        =   -1  'True
      BackStyle       =   0  'Transparent
      Caption         =   "学生修改个人信息"
      BeginProperty Font 
         Name            =   "Arial"
         Size            =   9.75
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00FFFFFF&
      Height          =   240
      Left            =   3120
      TabIndex        =   1
      Top             =   120
      Width           =   2040
   End
   Begin VB.Image Imageicon 
      Height          =   315
      Left            =   2520
      Picture         =   "frmstuperupdate.frx":0D9A
      Stretch         =   -1  'True
      Top             =   120
      Width           =   315
   End
   Begin VB.Image imgWindowBottomRight 
      Height          =   450
      Left            =   1080
      Picture         =   "frmstuperupdate.frx":11B6
      Top             =   0
      Width           =   285
   End
   Begin VB.Image imgWindowBottomLeft 
      Height          =   450
      Left            =   720
      Picture         =   "frmstuperupdate.frx":1900
      Top             =   0
      Width           =   285
   End
   Begin VB.Image imgTitleMain 
      Height          =   450
      Left            =   0
      Picture         =   "frmstuperupdate.frx":204A
      Stretch         =   -1  'True
      Top             =   450
      Width           =   285
   End
   Begin VB.Image imgWindowBottom 
      Height          =   450
      Left            =   360
      Picture         =   "frmstuperupdate.frx":2794
      Stretch         =   -1  'True
      Top             =   480
      Width           =   285
   End
   Begin VB.Image imgTitleRight 
      Height          =   450
      Left            =   360
      Picture         =   "frmstuperupdate.frx":2EDE
      Top             =   0
      Width           =   285
   End
   Begin VB.Image imgTitleLeft 
      Height          =   450
      Left            =   0
      Picture         =   "frmstuperupdate.frx":3628
      Top             =   0
      Width           =   285
   End
   Begin VB.Image imgWindowRight 
      Height          =   450
      Left            =   720
      Picture         =   "frmstuperupdate.frx":3D72
      Stretch         =   -1  'True
      Top             =   480
      Width           =   285
   End
   Begin VB.Image imgWindowLeft 
      Height          =   450
      Left            =   1080
      Picture         =   "frmstuperupdate.frx":44BC
      Stretch         =   -1  'True
      Top             =   480
      Width           =   285
   End
   Begin VB.Label Label1 
      BackStyle       =   0  'Transparent
      Caption         =   "学生修改个人信息"
      BeginProperty Font 
         Name            =   "华文行楷"
         Size            =   15.75
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   2640
      TabIndex        =   0
      Top             =   600
      Width           =   2655
   End
End
Attribute VB_Name = "frmstuperupdate"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
 Dim strsql As String
  Dim rs As ADODB.Recordset
  Dim MsgText As String

Private Sub exitcomm_Click()
 Unload Me
End Sub



Private Sub Form_Load()
MakeWindow Me
strsql = "select * from student where Sno='" & user_name & "'"
  Set rs = MyDB.ExecuteSQL(strsql, MsgText)
If Not rs.EOF Then
 Label12.Caption = rs.Fields(0)
 Label13.Caption = rs.Fields(1)
 Label14.Caption = rs.Fields(2)
 Label16.Caption = rs.Fields(5)
 Label15.Caption = rs.Fields(4)
 Label17.Caption = rs.Fields(6)
 Text1.Text = rs.Fields(3)
 Text2.Text = rs.Fields(7)
 Text3.Text = rs.Fields(8)
 Text4.Text = rs.Fields(9)
 End If
rs.Close
End Sub
Private Sub imgTitleclose_Click()
    intNumField = -2
    Unload Me
End Sub

Private Sub imgTitleLeft_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    DoDrag Me
End Sub

Private Sub imgTitleMain_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    DoDrag Me
End Sub

Private Sub imgTitleMinimize_Click()
    Me.WindowState = 1
End Sub

Private Sub imgTitleRight_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    DoDrag Me
End Sub

Private Sub lblTitle_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    DoDrag Me
End Sub


Private Sub oksavecomm_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
strsql = "select * from student  where Sno='" & Label12.Caption & "'"
  Set rs = MyDB.ExecuteSQL(strsql, MsgText)
   On Error Resume Next
 If Not rs.EOF Then
   rs.Update
   rs.Fields(0) = Label12.Caption
   rs.Fields(1) = Label13.Caption
   rs.Fields(2) = Label14.Caption
   rs.Fields(5) = Label16.Caption
   rs.Fields(4) = Label15.Caption
   rs.Fields(6) = Label17.Caption
   rs.Fields(3) = Text1.Text
   rs.Fields(7) = Text2.Text
   rs.Fields(8) = Text3.Text
   rs.Fields(9) = Text4.Text
   rs.Update
   MsgBox "修改信息成功!", vbOKOnly + vbExclamation, "提示"
   Unload Me
 Else
  MsgBox "你不属于学生", vbInformation + vbOKOnly, "提示"
  End If
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -