vb 窗体最大化时怎么使背景图片跟着改变大小
展开全部
Form_Resize 事件
下面是例子,具体设多少自己定
Private Sub Form_Resize()
'if Picture1.Height < ** then ...觉得有必要的条件自己加
Picture1.Height =Me.Height- 100
Picture1.Width= Me.Width -100
End Sub
下面是例子,具体设多少自己定
Private Sub Form_Resize()
'if Picture1.Height < ** then ...觉得有必要的条件自己加
Picture1.Height =Me.Height- 100
Picture1.Width= Me.Width -100
End Sub
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
这个方法最好
Private Sub Form_Resize()
'if Picture1.Height < ** then ...觉得有必要的条件自己加
Picture1.Height =Me.Height- 100
Picture1.Width= Me.Width -100
End Sub
Private Sub Form_Resize()
'if Picture1.Height < ** then ...觉得有必要的条件自己加
Picture1.Height =Me.Height- 100
Picture1.Width= Me.Width -100
End Sub
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
Option Explicit
Private BackGround As StdPicture
Private Sub Form_Load()
Set BackGround = Me.Picture
Me.Picture = LoadPicture("")
Me.AutoRedraw = True
End Sub
Private Sub Form_Resize()
Me.PaintPicture BackGround, 0, 0, Me.ScaleWidth, Me.ScaleHeight
End Sub
Private BackGround As StdPicture
Private Sub Form_Load()
Set BackGround = Me.Picture
Me.Picture = LoadPicture("")
Me.AutoRedraw = True
End Sub
Private Sub Form_Resize()
Me.PaintPicture BackGround, 0, 0, Me.ScaleWidth, Me.ScaleHeight
End Sub
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询