Form1.frm
上传用户:xzhdjhq
上传日期:2013-04-04
资源大小:302k
文件大小:4k
源码类别:

软件工程

开发平台:

Visual Basic

  1. VERSION 5.00
  2. Begin VB.Form Form1 
  3.    BorderStyle     =   1  'Fixed Single
  4.    Caption         =   "软件0302runnerup"
  5.    ClientHeight    =   3195
  6.    ClientLeft      =   2550
  7.    ClientTop       =   2325
  8.    ClientWidth     =   4680
  9.    LinkTopic       =   "Form1"
  10.    ScaleHeight     =   3195
  11.    ScaleWidth      =   4680
  12.    Begin VB.CommandButton Command2 
  13.       Caption         =   "退出"
  14.       Height          =   375
  15.       Left            =   3120
  16.       TabIndex        =   6
  17.       Top             =   2640
  18.       Width           =   1095
  19.    End
  20.    Begin VB.CommandButton Command1 
  21.       Caption         =   "登录"
  22.       Height          =   375
  23.       Left            =   1560
  24.       TabIndex        =   5
  25.       Top             =   2640
  26.       Width           =   1215
  27.    End
  28.    Begin VB.TextBox Text2 
  29.       Height          =   375
  30.       IMEMode         =   3  'DISABLE
  31.       Left            =   1560
  32.       PasswordChar    =   "*"
  33.       TabIndex        =   4
  34.       Text            =   "admin"
  35.       Top             =   1800
  36.       Width           =   1455
  37.    End
  38.    Begin VB.TextBox Text1 
  39.       Height          =   375
  40.       Left            =   1560
  41.       TabIndex        =   3
  42.       Text            =   "admin"
  43.       Top             =   960
  44.       Width           =   1455
  45.    End
  46.    Begin VB.Label Label3 
  47.       Caption         =   "密码"
  48.       BeginProperty Font 
  49.          Name            =   "宋体"
  50.          Size            =   10.5
  51.          Charset         =   134
  52.          Weight          =   700
  53.          Underline       =   0   'False
  54.          Italic          =   0   'False
  55.          Strikethrough   =   0   'False
  56.       EndProperty
  57.       Height          =   375
  58.       Left            =   720
  59.       TabIndex        =   2
  60.       Top             =   1800
  61.       Width           =   855
  62.    End
  63.    Begin VB.Label Label2 
  64.       Caption         =   "用户名"
  65.       BeginProperty Font 
  66.          Name            =   "宋体"
  67.          Size            =   10.5
  68.          Charset         =   134
  69.          Weight          =   700
  70.          Underline       =   0   'False
  71.          Italic          =   0   'False
  72.          Strikethrough   =   0   'False
  73.       EndProperty
  74.       Height          =   375
  75.       Left            =   720
  76.       TabIndex        =   1
  77.       Top             =   1080
  78.       Width           =   735
  79.    End
  80.    Begin VB.Label Label1 
  81.       Caption         =   "仓库管理系统"
  82.       BeginProperty Font 
  83.          Name            =   "宋体"
  84.          Size            =   18
  85.          Charset         =   134
  86.          Weight          =   400
  87.          Underline       =   0   'False
  88.          Italic          =   0   'False
  89.          Strikethrough   =   0   'False
  90.       EndProperty
  91.       Height          =   615
  92.       Left            =   1080
  93.       TabIndex        =   0
  94.       Top             =   240
  95.       Width           =   2895
  96.    End
  97. End
  98. Attribute VB_Name = "Form1"
  99. Attribute VB_GlobalNameSpace = False
  100. Attribute VB_Creatable = False
  101. Attribute VB_PredeclaredId = True
  102. Attribute VB_Exposed = False
  103. Private Sub Command1_Click()
  104. Dim pubConn As New ADODB.Connection
  105. Dim rsTable As New ADODB.Recordset
  106. Dim strSQL As String
  107. pubConn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;" & "Data Source=" & App.Path & "runnerup.mdb" & ";" & "Persist Security Info=False"
  108. pubConn.ConnectionTimeout = 30
  109. pubConn.Open
  110. rsTable.CursorLocation = adUseClient
  111. strSQL = "select 用户名 from user11 where user11.用户名='" & Trim(Text1.Text) & "' and user11.密码='" & Trim(Text2.Text) & "'"
  112. rsTable.Open strSQL, pubConn, adOpenDynamic, adLockOptimistic
  113. If rsTable.EOF = True And rsTable.BOF Then
  114.     m = MsgBox("请重新登录", vbExclamation)
  115.     Text1.Text = ""
  116.     Text1.SetFocus
  117.     Else
  118.     Unload Me
  119.     Form2.Show
  120.     End If
  121. End Sub
  122. Private Sub RealAudio1_OnGotoURL(ByVal url As String, ByVal target As String)
  123. End Sub
  124. Private Sub DataCombo1_Click(Area As Integer)
  125. End Sub
  126. Private Sub Command2_Click()
  127. Unload Me
  128. End Sub