📄 frmimagelist.frm
字号:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Begin VB.Form frmImages
AutoRedraw = -1 'True
Caption = "Fig. 11.35: Using an ImageList Control"
ClientHeight = 3000
ClientLeft = 5100
ClientTop = 4185
ClientWidth = 4725
LinkTopic = "Form1"
ScaleHeight = 3000
ScaleWidth = 4725
Begin MSComctlLib.ImageList ilsTheImages
Left = 1920
Top = 240
_ExtentX = 1005
_ExtentY = 1005
BackColor = -2147483643
ImageWidth = 39
ImageHeight = 38
MaskColor = 12632256
_Version = 393216
BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628}
NumListImages = 6
BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmImageList.frx":0000
Key = ""
EndProperty
BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmImageList.frx":0A42
Key = ""
EndProperty
BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmImageList.frx":1484
Key = ""
EndProperty
BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmImageList.frx":1EC6
Key = ""
EndProperty
BeginProperty ListImage5 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmImageList.frx":2908
Key = ""
EndProperty
BeginProperty ListImage6 {2C247F27-8591-11D1-B16A-00C0F0283628}
Picture = "frmImageList.frx":334A
Key = ""
EndProperty
EndProperty
End
Begin VB.Timer tmrClock
Left = 1800
Top = 1320
End
End
Attribute VB_Name = "frmImages"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
' Fig. 11.35
' Using an ImageList control.
Option Explicit
Private Sub Form_Load()
Call Randomize
tmrClock.Interval = 500 ' Milliseconds
End Sub
Private Sub tmrClock_Timer()
Dim r As Integer
r = Int(6 * Rnd()) + 1
' Draw an image from ilsTheImages at a random position
' on the form.
Call PaintPicture(ilsTheImages.ListImages(r).Picture, _
Rnd() * Width, Rnd() * Height)
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -