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

📄 frm_backchange.frm

📁 基于vb的图书管理系统的设计
💻 FRM
字号:
VERSION 5.00
Begin VB.Form frm_BackChange 
   BorderStyle     =   1  'Fixed Single
   Caption         =   "更换背景对话框"
   ClientHeight    =   3645
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   5910
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   3645
   ScaleWidth      =   5910
   StartUpPosition =   2  '屏幕中心
   Begin VB.Frame Frame2 
      Caption         =   "选择图片"
      Height          =   3615
      Left            =   45
      TabIndex        =   1
      Top             =   0
      Width           =   1860
      Begin VB.CommandButton cmdCustom 
         Caption         =   "自定义..."
         Height          =   330
         Left            =   315
         TabIndex        =   10
         Top             =   3105
         Width           =   1185
      End
      Begin VB.Frame Frame3 
         Height          =   2670
         Left            =   180
         TabIndex        =   3
         Top             =   270
         Width           =   1500
         Begin VB.OptionButton Option1 
            Caption         =   "湖光山色"
            Height          =   285
            Index           =   5
            Left            =   225
            TabIndex        =   9
            Top             =   2070
            Width           =   1050
         End
         Begin VB.OptionButton Option1 
            Caption         =   "帅哥登场"
            Height          =   285
            Index           =   4
            Left            =   225
            TabIndex        =   8
            Top             =   1701
            Width           =   1050
         End
         Begin VB.OptionButton Option1 
            Caption         =   "美丽少女"
            Height          =   285
            Index           =   3
            Left            =   225
            TabIndex        =   7
            Top             =   1332
            Width           =   1050
         End
         Begin VB.OptionButton Option1 
            Caption         =   "无限幻想"
            Height          =   285
            Index           =   2
            Left            =   225
            TabIndex        =   6
            Top             =   963
            Width           =   1050
         End
         Begin VB.OptionButton Option1 
            Caption         =   "乡村风光"
            Height          =   285
            Index           =   1
            Left            =   225
            TabIndex        =   5
            Top             =   594
            Width           =   1050
         End
         Begin VB.OptionButton Option1 
            Caption         =   "海底世界"
            Height          =   285
            Index           =   0
            Left            =   225
            TabIndex        =   4
            Top             =   225
            Width           =   1050
         End
      End
   End
   Begin VB.Frame Frame1 
      Caption         =   "预览图片"
      Height          =   3615
      Left            =   1935
      TabIndex        =   0
      Top             =   0
      Width           =   3930
      Begin VB.CommandButton cmdOK 
         Caption         =   "确定"
         Height          =   375
         Left            =   1845
         TabIndex        =   12
         Top             =   3150
         Width           =   960
      End
      Begin VB.CommandButton cmdCancel 
         Caption         =   "取消"
         Height          =   375
         Left            =   2835
         TabIndex        =   11
         Top             =   3150
         Width           =   960
      End
      Begin VB.CheckBox Check1 
         Caption         =   "无背景图片"
         Height          =   285
         Left            =   135
         TabIndex        =   2
         Top             =   3195
         Width           =   1500
      End
      Begin VB.Image Image1 
         BorderStyle     =   1  'Fixed Single
         Height          =   2760
         Left            =   135
         Stretch         =   -1  'True
         Top             =   225
         Width           =   3660
      End
   End
End
Attribute VB_Name = "frm_BackChange"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Dim strBackName As String

Private Sub Check1_Click()
If Check1.Value = 1 Then
  mfrm_Main.Picture = Nothing
  Image1.Picture = Nothing
Else
  Image1.Picture = LoadPicture(strBackName)
End If
End Sub

Private Sub cmdOK_Click()
If Check1.Value = 1 Then
  mfrm_Main.Picture = Nothing
  Image1.Picture = Nothing
Else
  mfrm_Main.Picture = LoadPicture(strBackName)
End If
Unload Me
End Sub

Private Sub Option1_Click(Index As Integer)
Dim i As Integer
If Check1.Value = 1 Then
 Exit Sub
End If
For i = 0 To 5
 If Option1.Item(i).Value = True Then
   Image1.Picture = LoadPicture(App.Path & "\images\backimage\" & Option1.Item(i).Caption & ".jpg")
   strBackName = App.Path & "\images\backimage\" & Option1.Item(i).Caption & ".jpg"
 End If
Next i
End Sub

⌨️ 快捷键说明

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