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

📄 frmpic.frm

📁 针对各种管理系统提供有的VB源代码
💻 FRM
字号:
VERSION 5.00
Begin VB.Form FRMPIC 
   AutoRedraw      =   -1  'True
   Caption         =   "Form1"
   ClientHeight    =   8595
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   11880
   LinkTopic       =   "Form1"
   ScaleHeight     =   8595
   ScaleWidth      =   11880
   StartUpPosition =   3  'Windows Default
   Begin VB.PictureBox tu1 
      AutoSize        =   -1  'True
      Height          =   540
      Left            =   4470
      Picture         =   "FRMPIC.frx":0000
      ScaleHeight     =   480
      ScaleWidth      =   480
      TabIndex        =   10
      Top             =   2100
      Visible         =   0   'False
      Width           =   540
   End
   Begin VB.PictureBox tu3 
      AutoSize        =   -1  'True
      Height          =   540
      Left            =   2370
      Picture         =   "FRMPIC.frx":0442
      ScaleHeight     =   480
      ScaleWidth      =   480
      TabIndex        =   9
      Top             =   4140
      Visible         =   0   'False
      Width           =   540
   End
   Begin VB.PictureBox tu4 
      AutoSize        =   -1  'True
      Height          =   540
      Left            =   10050
      Picture         =   "FRMPIC.frx":0884
      ScaleHeight     =   480
      ScaleWidth      =   480
      TabIndex        =   8
      Top             =   2310
      Visible         =   0   'False
      Width           =   540
   End
   Begin VB.PictureBox tu2 
      AutoSize        =   -1  'True
      Height          =   540
      Left            =   6600
      Picture         =   "FRMPIC.frx":0CC6
      ScaleHeight     =   480
      ScaleWidth      =   480
      TabIndex        =   7
      Top             =   3390
      Visible         =   0   'False
      Width           =   540
   End
   Begin VB.CommandButton Command3 
      Caption         =   "保存"
      Height          =   375
      Left            =   9720
      TabIndex        =   6
      Top             =   8040
      Width           =   645
   End
   Begin VB.CommandButton Command2 
      Caption         =   "关闭"
      Height          =   375
      Left            =   11160
      TabIndex        =   4
      Top             =   8040
      Width           =   615
   End
   Begin VB.CommandButton Command1 
      Caption         =   "后退"
      Height          =   375
      Left            =   10440
      Picture         =   "FRMPIC.frx":1108
      TabIndex        =   2
      Top             =   8040
      Width           =   615
   End
   Begin VB.Label Label1 
      BackStyle       =   0  'Transparent
      Caption         =   "海洋"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   13.5
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00000000&
      Height          =   4335
      Left            =   0
      TabIndex        =   5
      Top             =   0
      Width           =   6495
   End
   Begin VB.Label Label2 
      BackStyle       =   0  'Transparent
      Caption         =   "植物"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   13.5
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H000000FF&
      Height          =   4335
      Left            =   6510
      TabIndex        =   3
      Top             =   0
      Width           =   5415
   End
   Begin VB.Label Label4 
      BackStyle       =   0  'Transparent
      Caption         =   "高山"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   13.5
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H0000FF00&
      Height          =   4335
      Left            =   6450
      TabIndex        =   1
      Top             =   4320
      Width           =   5415
   End
   Begin VB.Label Label3 
      BackStyle       =   0  'Transparent
      Caption         =   "城市"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   13.5
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00FF0000&
      Height          =   4335
      Left            =   0
      TabIndex        =   0
      Top             =   4320
      Width           =   6495
   End
End
Attribute VB_Name = "FRMPIC"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim X As Integer
Dim Pic(100) As Picture

Private Sub Command1_Click()
    tu1.Visible = False
    tu2.Visible = False
    tu3.Visible = False
    tu4.Visible = False
    If X = 1 Or X = 2 Or X = 3 Or X = 4 Then
        X = 0
        Label1.Caption = "海洋"
        Label2.Caption = "植物"
        Label3.Caption = "城市"
        Label4.Caption = "高山"
        'Label1.Style = 0
        'Label2.Style = 0
        'Label3.Style = 0
        'Label4.Style = 0
        'Set Pic(1) = LoadPicture(App.Path + "\h1.jpg")
    End If
    If X = 11 Or X = 12 Or X = 13 Or X = 14 Then
        X = 1
        'Set Pic(1) = LoadPicture(App.Path + "\001.jpg")
    End If
    If X = 21 Or X = 22 Or X = 23 Or X = 24 Then
        X = 2
        'Set Pic(2) = LoadPicture(App.Path + "\002.jpg")
    End If
    If X = 31 Or X = 32 Or X = 33 Or X = 34 Then
        X = 3
        'Set Pic(3) = LoadPicture(App.Path + "\003.jpg")
    End If
    If X = 41 Or X = 42 Or X = 43 Or X = 44 Then
        X = 4
        'Set Pic(4) = LoadPicture(App.Path + "\004.jpg")
    End If
    
    PaintPicture Pic(X), 0, 0
    FRMSBCX.Caption = X
End Sub

Private Sub Command2_Click()
    SBGCGL.Enabled = True
    Unload Me
    
End Sub

Private Sub Form_Load()
    
    X = 0
    Set Pic(0) = LoadPicture(App.Path + "\000004.jpg")
    Set Pic(1) = LoadPicture(App.Path + "\sea_10.jpg")
    Set Pic(2) = LoadPicture(App.Path + "\h1.jpg")
    Set Pic(3) = LoadPicture(App.Path + "\place_01.jpg")
    Set Pic(4) = LoadPicture(App.Path + "\005.jpg")
    Set Pic(11) = LoadPicture(App.Path + "\sea_11.jpg")
    Set Pic(12) = LoadPicture(App.Path + "\sea_12.jpg")
    Set Pic(13) = LoadPicture(App.Path + "\sea_13.jpg")
    Set Pic(14) = LoadPicture(App.Path + "\sea_14.jpg")
    Set Pic(21) = LoadPicture(App.Path + "\plant2-1.jpg")
    Set Pic(22) = LoadPicture(App.Path + "\plant2-2.jpg")
    Set Pic(23) = LoadPicture(App.Path + "\plant_08.jpg")
    Set Pic(24) = LoadPicture(App.Path + "\plant_07.jpg")
    Set Pic(31) = LoadPicture(App.Path + "\place_02.jpg")
    Set Pic(32) = LoadPicture(App.Path + "\place_03.jpg")
    Set Pic(33) = LoadPicture(App.Path + "\place_04.jpg")
    Set Pic(34) = LoadPicture(App.Path + "\place_05.jpg")
    Set Pic(41) = LoadPicture(App.Path + "\006.jpg")
    Set Pic(42) = LoadPicture(App.Path + "\007.jpg")
    Set Pic(43) = LoadPicture(App.Path + "\008.jpg")
    Set Pic(44) = LoadPicture(App.Path + "\009.jpg")
    Me.Show
    PaintPicture Pic(X), 0, 0
End Sub

Private Sub Label1_Click()
    If X = 1 Then
        X = 11
        PaintPicture Pic(X), 0, 0
        tu3.Visible = True
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 2 Then
        X = 21
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 3 Then
        X = 31
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 4 Then
        X = 41
        PaintPicture Pic(X), 0, 0
         tu1.Visible = True
        FRMSBCX.Caption = X
        Exit Sub
    End If
    
    If X = 0 Then
        X = 1
        Label1.Caption = ""
        Label2.Caption = ""
        Label3.Caption = ""
        Label4.Caption = ""
        Me.PaintPicture Pic(1), 0, 0
        FRMSBCX.Caption = X
        
    End If
    
    
End Sub

Private Sub Label2_Click()
    If X = 1 Then
        X = 12
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 2 Then
        X = 22
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 3 Then
        X = 32
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 4 Then
        X = 42
        PaintPicture Pic(X), 0, 0
        tu4.Visible = True
        FRMSBCX.Caption = X
        Exit Sub
    End If
    
    If X = 0 Then
        X = 2
        Label1.Caption = ""
        Label2.Caption = ""
        Label3.Caption = ""
        Label4.Caption = ""
        PaintPicture Pic(2), 0, 0
        FRMSBCX.Caption = X
        
    End If
    
        

    
End Sub

Private Sub Label3_Click()
        If X = 1 Then
        X = 13
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 2 Then
        X = 23
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 3 Then
        X = 33
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 4 Then
        X = 43
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    
    If X = 0 Then
        X = 3
        
        Label1.Caption = ""
        Label2.Caption = ""
        Label3.Caption = ""
        Label4.Caption = ""
        PaintPicture Pic(3), 0, 0
        FRMSBCX.Caption = X
    End If
    
End Sub

Private Sub Label4_Click()
    If X = 1 Then
        X = 14
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 2 Then
        X = 24
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 3 Then
        X = 34
        PaintPicture Pic(X), 0, 0
        FRMSBCX.Caption = X
        Exit Sub
    End If
    If X = 4 Then
        X = 44
        PaintPicture Pic(X), 0, 0
        tu2.Visible = True
        FRMSBCX.Caption = X
        Exit Sub
    End If
    
    If X = 0 Then
        X = 4
        
        Label1.Caption = ""
        Label2.Caption = ""
        Label3.Caption = ""
        Label4.Caption = ""
        PaintPicture Pic(4), 0, 0
        FRMSBCX.Caption = X
    End If
    
    
    
End Sub

Private Sub RichTextBox1_Change()
        
End Sub

Private Sub tu1_Click()
    SBBH = "13123"
    FRMSBCX.Show
    FRMSBCX.Adodc1.RecordSource = "SELECT * FROM 设备运行检查状况记录表 where 设备名称='" & SBBH & "'"
    FRMSBCX.Adodc1.Refresh
    FRMSBCX.Adodc1.Recordset.MoveLast
    Me.Enabled = False
End Sub

Private Sub tu2_Click()
    SBBH = "123"
    FRMSBCX.Show
    FRMSBCX.Adodc1.RecordSource = "SELECT * FROM 设备运行检查状况记录表 where 设备名称='" & SBBH & "'"
    FRMSBCX.Adodc1.Refresh
    FRMSBCX.Adodc1.Recordset.MoveLast
    Me.Enabled = False
End Sub

Private Sub tu3_Click()
    SBBH = "werwe"
    FRMSBCX.Show
    FRMSBCX.Adodc1.RecordSource = "SELECT * FROM 设备运行检查状况记录表 where 设备名称='" & SBBH & "'"
    FRMSBCX.Adodc1.Refresh
    FRMSBCX.Adodc1.Recordset.MoveLast
    Me.Enabled = False
End Sub

Private Sub tu4_Click()
    SBBH = "sdf"
    'Load FRMSBCX
    FRMSBCX.Show
    FRMSBCX.Adodc1.RecordSource = "SELECT * FROM 设备运行检查状况记录表 where 设备名称='" & SBBH & "'"
    FRMSBCX.Adodc1.Refresh
    FRMSBCX.Adodc1.Recordset.MoveLast
    Me.Enabled = False
End Sub

⌨️ 快捷键说明

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