28-11-15, 08:52 AM (آخر تعديل لهذه المشاركة : 28-11-15, 08:53 AM {2} بواسطة أبو عمر.)
PHP كود :
Public Class Form1
Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click 'اظهار الفورم الجديد على يمين الفورم الاول Dim frm1Width As Integer = Me.Width If Form2.Visible = False Then Form2.Show() Form2.Location = New Point(Me.Location.X + frm1Width, Me.Location.Y)
Else Form2.Hide()
End If End Sub Private Sub Button2_Click(sender As System.Object, e As System.EventArgs) Handles Button2.Click 'اظهار الفورم الجديد يسار الفورم الاول Dim frm1Width As Integer = Me.Width If Form3.Visible = False Then Form3.Show() Form3.Location = New Point(Me.Location.X - frm1Width, Me.Location.Y)
Else Form3.Hide()
End If End Sub
Private Sub Button3_Click(sender As System.Object, e As System.EventArgs) Handles Button3.Click 'اظهار الفورم الجديد فوق الفورم الاول Dim frm1Height As Integer = Me.Height If Form4.Visible = False Then Form4.Show() Form4.Location = New Point(Me.Location.X, Me.Location.Y - frm1Height)
Else Form4.Hide()
End If
End Sub
Private Sub Button4_Click(sender As System.Object, e As System.EventArgs) Handles Button4.Click 'اظهار الفورم الجديد تحت الفورم الاول Dim frm1Height As Integer = Me.Height If Form5.Visible = False Then Form5.Show() Form5.Location = New Point(Me.Location.X, Me.Location.Y + frm1Height)
Else Form5.Hide()
End If End Sub End Class
[align=center
] [/align]
سبحان الله والحمدللهولا إله إلا الله والله أكبر
اللهم اغْفِرْ لِلمؤمنين والمؤمنات والمسلمين والمسلمات الأحياء منهم والأموات
Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click 'اظهار الفورم الجديد على يمين الفورم الاول Dim frm1Width As Integer = Me.Width If Form2.Visible = False Then Form2.Show() Form2.Location = New Point(Me.Location.X + frm1Width, Me.Location.Y)
Else Form2.Hide()
End If End Sub Private Sub Button2_Click(sender As System.Object, e As System.EventArgs) Handles Button2.Click 'اظهار الفورم الجديد يسار الفورم الاول Dim frm1Width As Integer = Me.Width If Form3.Visible = False Then Form3.Show() Form3.Location = New Point(Me.Location.X - frm1Width, Me.Location.Y)
Else Form3.Hide()
End If End Sub
Private Sub Button3_Click(sender As System.Object, e As System.EventArgs) Handles Button3.Click 'اظهار الفورم الجديد فوق الفورم الاول Dim frm1Height As Integer = Me.Height If Form4.Visible = False Then Form4.Show() Form4.Location = New Point(Me.Location.X, Me.Location.Y - frm1Height)
Else Form4.Hide()
End If
End Sub
Private Sub Button4_Click(sender As System.Object, e As System.EventArgs) Handles Button4.Click 'اظهار الفورم الجديد تحت الفورم الاول Dim frm1Height As Integer = Me.Height If Form5.Visible = False Then Form5.Show() Form5.Location = New Point(Me.Location.X, Me.Location.Y + frm1Height)
Else Form5.Hide()
End If End Sub End Class
[align=center
] [/align]
جزاك الله خير مع انى جربت (Form3.Location = New Point(Me.Location.X , Me.Location.Y و لم يعمل اعتقد السبب + - Height Width