📄 vb中如何平铺显示图片.txt
字号:
你 可 以 Form上 放 置 一 个 PictureBox, 将 Visible属 性 设 为 False, AutoSize属 性 设 为 True。 将 PictureBox的 Picture属 性 设 置 为 你 需 要 的 图 片 。 然 后 在 Form_Paint事 件 中 输 入 如 下 代 码 :
Private Sub Form_Paint()
Dim wid As Single
Dim hgt As Single
Dim x As Single
Dim y As Single
wid = Picture1.ScaleWidth
hgt = Picture1.ScaleHeight
y = 0
Do While y < ScaleHeight
x = 0
Do While x < ScaleWidth
PaintPicture Picture1.Picture, _
x, y, wid, hgt
x = x + wid
Loop
y = y + hgt
Loop
End Sub
<END>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -