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

📄 frm_infoset.frm

📁 卧虎山水库监测管理程序:包含实时数据浏览、历史数据浏览以及曲线绘制
💻 FRM
字号:
VERSION 5.00
Begin VB.Form Frm_InfoSet 
   BackColor       =   &H00F0BB79&
   Caption         =   " 水 库 基 本 信 息 设 置"
   ClientHeight    =   4620
   ClientLeft      =   60
   ClientTop       =   450
   ClientWidth     =   9000
   BeginProperty Font 
      Name            =   "宋体"
      Size            =   10.5
      Charset         =   134
      Weight          =   400
      Underline       =   0   'False
      Italic          =   0   'False
      Strikethrough   =   0   'False
   EndProperty
   Icon            =   "Frm_InfoSet.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   ScaleHeight     =   4620
   ScaleWidth      =   9000
   StartUpPosition =   1  '所有者中心
   Begin VB.Frame Frame1 
      BackColor       =   &H00F0BB79&
      ForeColor       =   &H00FF0000&
      Height          =   2895
      Left            =   120
      TabIndex        =   11
      Top             =   0
      Width           =   8775
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   0
         Left            =   1560
         MaxLength       =   50
         TabIndex        =   1
         Top             =   360
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   8
         Left            =   5760
         TabIndex        =   8
         Top             =   1800
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   7
         Left            =   5760
         TabIndex        =   6
         Top             =   1320
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   6
         Left            =   5760
         TabIndex        =   4
         Top             =   840
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   5
         Left            =   5760
         TabIndex        =   2
         Top             =   360
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   4
         Left            =   1560
         TabIndex        =   9
         Top             =   2280
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   3
         Left            =   1560
         TabIndex        =   7
         Top             =   1800
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   2
         Left            =   1560
         TabIndex        =   5
         Top             =   1320
         Width           =   1695
      End
      Begin VB.TextBox Txt 
         Alignment       =   2  'Center
         Height          =   375
         Index           =   1
         Left            =   1560
         TabIndex        =   3
         Top             =   840
         Width           =   1695
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "放水流量:                  立方/秒"
         Height          =   210
         Index           =   8
         Left            =   4680
         TabIndex        =   20
         Top             =   1920
         Width           =   3675
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "溢洪流量:                  立方/秒"
         Height          =   210
         Index           =   7
         Left            =   4680
         TabIndex        =   19
         Top             =   1440
         Width           =   3675
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "蓄 水 量:                  百万方"
         Height          =   210
         Index           =   6
         Left            =   4680
         TabIndex        =   18
         Top             =   960
         Width           =   3570
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "水    位:                  米"
         Height          =   210
         Index           =   5
         Left            =   4680
         TabIndex        =   17
         Top             =   480
         Width           =   3150
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "汛末蓄水位:"
         Height          =   210
         Index           =   4
         Left            =   270
         TabIndex        =   16
         Top             =   2400
         Width           =   1260
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "汛限水位:"
         Height          =   210
         Index           =   3
         Left            =   480
         TabIndex        =   15
         Top             =   1920
         Width           =   1050
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "总 库 容:                  百万方"
         Height          =   210
         Index           =   2
         Left            =   480
         TabIndex        =   14
         Top             =   1440
         Width           =   3570
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "坝顶高程:                  米"
         Height          =   210
         Index           =   1
         Left            =   480
         TabIndex        =   13
         Top             =   960
         Width           =   3150
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "水库名称:"
         Height          =   210
         Index           =   0
         Left            =   480
         TabIndex        =   12
         Top             =   480
         Width           =   1050
      End
   End
   Begin VB.Frame Frame2 
      BackColor       =   &H00F0BB79&
      Height          =   1575
      Left            =   120
      TabIndex        =   21
      Top             =   2880
      Width           =   8775
      Begin VB.CommandButton Cmd_Save 
         Caption         =   "保存(&S)"
         Enabled         =   0   'False
         Height          =   975
         Left            =   3600
         Picture         =   "Frm_InfoSet.frx":058A
         Style           =   1  'Graphical
         TabIndex        =   10
         Top             =   360
         Width           =   1095
      End
      Begin VB.CommandButton Command1 
         Caption         =   "修改(M)"
         Height          =   975
         Left            =   1080
         Picture         =   "Frm_InfoSet.frx":09CC
         Style           =   1  'Graphical
         TabIndex        =   0
         Top             =   360
         Width           =   1095
      End
      Begin VB.CommandButton Cmd_S_Exit 
         Caption         =   "返回(&Q)"
         Height          =   975
         Left            =   6120
         Picture         =   "Frm_InfoSet.frx":0E9F
         Style           =   1  'Graphical
         TabIndex        =   22
         Top             =   360
         Width           =   1095
      End
   End
End
Attribute VB_Name = "Frm_InfoSet"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Cmd_S_Exit_Click()
    Unload Me
End Sub

Private Sub Cmd_Save_Click()
    Open_Data ("select * from ST_SKInfo ")
    If rs.RecordCount > 0 Then 'SK_Name,SK_BaHigh,SK_ZKR,SK_XQSW,SK_XQXSW,SK_SW,SK_XSL,SK_YHLL,SK_FSLL
        Open_Data ("update ST_SKInfo set SK_Name='" & Txt(0).Text & "',SK_BaHigh='" & Val(Txt(1).Text) & "',SK_ZKR='" & Val(Txt(2).Text) & "',SK_XQSW='" & Val(Txt(3).Text) & "',SK_XQXSW='" & Val(Txt(4).Text) & "',SK_SW='" & Val(Txt(5).Text) & "',SK_XSL='" & Val(Txt(6).Text) & "',SK_YHLL='" & Val(Txt(7).Text) & "',SK_FSLL='" & Val(Txt(8).Text) & "'")
    Else
        Open_Data ("insert into ST_SKInfo values('" & Txt(0).Text & "','" & Val(Txt(1).Text) & "','" & Val(Txt(2).Text) & "','" & Val(Txt(3).Text) & "','" & Val(Txt(4).Text) & "','" & Val(Txt(5).Text) & "','" & Val(Txt(6).Text) & "','" & Val(Txt(7).Text) & "','" & Val(Txt(8).Text) & "')")
    End If
    
    For i = 0 To 8
        Txt(i).Enabled = False
    Next i
    Cmd_Save.Enabled = False
    Command1.Enabled = True

End Sub

Private Sub Command1_Click()
    For i = 0 To 8
        Txt(i).Enabled = True
    Next i
    Cmd_Save.Enabled = True
    Command1.Enabled = False
End Sub

Private Sub Form_Load()
    For i = 0 To 8
        Txt(i).Enabled = False
    Next i
    
    Open_Data ("select * from ST_SKInfo ")
    If rs.RecordCount > 0 Then
        rs.MoveFirst
        For i = 0 To 8
            Txt(i).Text = rs.Fields(i)
        Next i
    End If
    
End Sub

⌨️ 快捷键说明

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