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

📄 frminput.frm

📁 管理信息系统my sql++ visual bassic
💻 FRM
📖 第 1 页 / 共 2 页
字号:
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   10
      Left            =   120
      TabIndex        =   10
      Top             =   3720
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "主修:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   9
      Left            =   120
      TabIndex        =   9
      Top             =   3360
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "电子邮件:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   8
      Left            =   120
      TabIndex        =   8
      Top             =   3000
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "电话号码:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   7
      Left            =   120
      TabIndex        =   7
      Top             =   2640
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "邮政编码:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   6
      Left            =   120
      TabIndex        =   6
      Top             =   2280
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "省份:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   5
      Left            =   120
      TabIndex        =   5
      Top             =   1920
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "所在城市:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   4
      Left            =   120
      TabIndex        =   4
      Top             =   1560
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "家庭地址:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   3
      Left            =   120
      TabIndex        =   3
      Top             =   1200
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "父母姓名:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   2
      Left            =   120
      TabIndex        =   2
      Top             =   840
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "姓氏:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   1
      Left            =   120
      TabIndex        =   1
      Top             =   480
      Width           =   1095
   End
   Begin VB.Label Label1 
      Caption         =   "姓名:"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   255
      Index           =   0
      Left            =   120
      TabIndex        =   0
      Top             =   120
      Width           =   1095
   End
End
Attribute VB_Name = "FrmInput"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Private Sub Command1_Click()
    On Error GoTo AddErr
        Adodc1.Recordset.AddNew
        Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command10_Click()
    On Error GoTo AddErr
        If MsgBox("你确信吗?", vbOKCancel, "警告") = vbOK Then
        Adodc1.Recordset.Delete
        Adodc1.Recordset.MoveFirst
        Exit Sub
        End If
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command2_Click()
    On Error GoTo AddErr
        Adodc1.Recordset.MoveFirst
        Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command3_Click()
    On Error GoTo AddErr
        Adodc1.Recordset.MoveLast
        Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command4_Click()
    On Error GoTo AddErr
        If Adodc1.Recordset.EOF Then Exit Sub
        Adodc1.Recordset.MoveNext
        Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command5_Click()
    On Error GoTo AddErr
        If Adodc1.Recordset.BOF Then Exit Sub
        Adodc1.Recordset.MovePrevious
        Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command6_Click()
    On Error GoTo AddErr
        Adodc1.Recordset.Update
        Exit Sub
AddErr:
    MsgBox Err.Description
End Sub

Private Sub Command7_Click()
    DlgCourse.Show (1)
End Sub

Private Sub Command8_Click()
    DlgAch.Show (1)
End Sub

Private Sub Command9_Click()
    Unload Me
End Sub

Private Sub Form_Load()
    MakeCenter FrmInput
    Adodc1.ConnectionString = "Provider=SQLOLEDB;Data Source=INET;User Id=sa;PWd=322167;Initial Catalog=学生信息"
    Adodc1.RecordSource = "SELECT * FROM 学生"
    Text1.DataField = "名字"
    Text2.DataField = "姓氏"
    Text3.DataField = "父母姓名"
    Text4.DataField = "地址"
    Text5.DataField = "城市"
    Text6.DataField = "省份"
    Text7.DataField = "邮政编码"
    Text8.DataField = "电话号码"
    Text9.DataField = "电子邮件帐号名"
    Text10.DataField = "主修"
    Text11.DataField = "学号"
    Text12.DataField = "附注"
    Label3.DataField = "学生ID"
End Sub

Private Sub Form_Unload(Cancel As Integer)
On Error Resume Next
    Adodc1.Recordset.Close
End Sub

Private Sub Text2_GotFocus()
    If Text2.Text = "" Then
        If Text1.Text <> "" Then
            Text2.Text = Left$(Text1.Text, 1)
        End If
    End If
End Sub

⌨️ 快捷键说明

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