Private Sub maximize()
maximizebutt.Image = My.Resources.maximize1
maximized = False
isresizable = False
isdragable = False
lastleft = Left
lasttop = Top
lastsize = Size
Left = 0
Top = 0
Width = My.Computer.Screen.Bounds.Width
Height = My.Computer.Screen.WorkingArea.Height
End Sub
Private Sub tonormal()
maximizebutt.Image = My.Resources.maximize
maximized = True
isresizable = True
isdragable = True
Size = lastsize
Left = lastleft
Top = lasttop
End Sub
Private Sub maximizebutt_MouseClick(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles maximizebutt.MouseClick
If maximized Then
maximize()
Else
tonormal()
End If
End Sub
Kód funguje, ale změna obrázku v pictureboxu maximizebutt nefunguje. V čem je problém?
|