📄 frm_usercode.frm
字号:
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "Msflxgrd.ocx"
Begin VB.Form Frm_UserCode
Caption = "用户代码选择"
ClientHeight = 6225
ClientLeft = 60
ClientTop = 345
ClientWidth = 5070
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 6225
ScaleWidth = 5070
StartUpPosition = 2 '屏幕中心
Begin VB.Frame Frame1
Height = 6135
Left = 90
TabIndex = 0
Top = 0
Width = 4905
Begin MSFlexGridLib.MSFlexGrid Grid1
Height = 5805
Left = 120
TabIndex = 1
Top = 210
Width = 4665
_ExtentX = 8229
_ExtentY = 10239
_Version = 393216
Cols = 3
Appearance = 0
End
End
End
Attribute VB_Name = "Frm_UserCode"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Form_Load()
Grid1.FormatString = " 用户代码 |^ 用户名称 |^ 用户级别 "
Dim i As Integer
Dim strSql As String
Dim m_Rs As New ADODB.Recordset
Set m_Rs = ExecuteSQL(strSql, "Person.Mdb")
'''''''将记录显示在表格中'''''''''''''''
strSql = "Select * From UserInfo Order By ID"
Set m_Rs = ExecuteSQL(strSql, "person.mdb")
i = 2
Do While Not m_Rs.EOF
Grid1.Rows = i + 1
Grid1.TextMatrix(i - 1, 0) = m_Rs("UserID")
Grid1.TextMatrix(i - 1, 1) = m_Rs("UserName")
Grid1.TextMatrix(i - 1, 2) = m_Rs("UserLevel")
m_Rs.MoveNext
i = i + 1
Loop
End Sub
Private Sub Grid1_DblClick()
Frm_EditPassword.Text1.Text = Frm_UserCode.Grid1.TextMatrix(Frm_UserCode.Grid1.Row, 0)
Frm_EditPassword.Text2.Text = Frm_UserCode.Grid1.TextMatrix(Frm_UserCode.Grid1.Row, 1)
Unload Me
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -