28-01-22, 04:26 AM
(28-01-22, 03:28 AM)سعود كتب :PHP كود :
TextBox2.Text = TextBox1.Lines(1)هذا الكود يلبي المطلوب ..جربته الان قبل كتابته هناالسطر الثاني هو اللذي تم اختياره لان الترقيم يبدأ من 0 الصفر.
PHP كود :
Private Sub TextBox1_MouseClick(sender As Object, e As MouseEventArgs) Handles TextBox1.MouseClick
If e.Button = MouseButtons.Left Then
Dim charIndex As Integer = TextBox1.GetCharIndexFromPosition(e.Location)
Dim line As Integer = TextBox1.GetLineFromCharIndex(charIndex)
TextBox2.Text = TextBox1.Lines(line)
End If
End Sub
شكرا لك اخي سعود الله يحفظك
