It is required that each time the window is clicked, the size of the window is expanded by 10%, and when the window is clicked for the seventh time, the window is maximized.
I mainly don’t know what idea to write this loop statement
Thank you
i = i + 1
Form1.Width = Screen.Width / 7 * i
Form1.Height = Screen.Height / 7 * i
Form1.Left = (Screen.Width-Form1.Width) / 2
Form1.Top = (Screen.Height-Form1.Height) / 2
If i = 7 Then i = 1
End Sub
Private Sub Form_Load()
Form1.AutoRedraw = True
End Sub
Thank youeltada
By the way, does Me mean the current form? After defining Dim, what is the default value of i? Thank you for answering again, I will reveal the post immediately