After check the value, The height increase. How I can make the form at center display after the form height increase?
Code:If Check5.Value = 1 Then
Frame50.Visible = True
Form41.Height = 10490
End if
Printable View
After check the value, The height increase. How I can make the form at center display after the form height increase?
Code:If Check5.Value = 1 Then
Frame50.Visible = True
Form41.Height = 10490
End if
Try this:
If Check5.Value = 1 Then
Frame50.Visible = True
Form41.Height = 10490
Form41.StartUpPosition = 2
End if
Quote:
Originally Posted by Yoosha
I got this error message. What does it mean?
Sorry :).
Try this:
Me.Move (Screen.Width - Me.Width) \ 2, (Screen.Height - Me.Height) \ 2
Or this:
Me.Top = (Screen.Height * 0.85) / 2 - Me.Height / 2
Me.Left = Screen.Width / 2 - Me.Width / 2
Ok. After check, the form go to center screen. That Fine.
How to make a form to center again, After i uncheck the checkbox
Code:
If Check5.Value = 1 Then
Frame50.Visible = True
Form41.Height = 10490
Me.Move (Screen.Width - Me.Width) \ 2, (Screen.Height - Me.Height) \ 2
Else
Frame50.Visible = False
Form41.Height = 2700
End If
No problem, Thats work.
If Check1.Value = 1 Then
Form41.Move (Screen.Width - Form41.Width) \ 2, (Screen.Height - Form41.Height) \ 2
Frame50.Visible = False
Form41.Height = 2700
Else
Form41.Move (Screen.Width - Form41.Width) \ 2, (Screen.Height - Form41.Height) \ 2
Frame50.Visible = False
Form41.Height = 2700
End If